<commit_before>window.Binco.Select2 =
  load: (selector) ->
    selector = if typeof selector == 'string' then selector else '.select2-rails'
    $(selector).select2()

$(document).on 'ready turbolinks:load', window.Binco.Select2.load
<commit_msg>destroy select2 on Turbolinks.visit restores<commit_after>window.Binco.Select2 =
  load: (selector) ->
    selector = if typeof selector == 'string' then selector else '.select2-rails'
    $(selector).each((i,e) ->
      $(e).select2('destroy') if $(e).hasClass("select2-hidden-accessible")
      $(e).select2()
    )

$(document).on 'turbolinks:load', window.Binco.Select2.load

{'fraction_non_alphanumeric': 0.16613418530351437, 'fraction_numerical': 0.01757188498402556, 'mean_word_length': 4.358974358974359, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1876138', 'n_tokens_mistral': 205, 'n_tokens_neox': 202, 'n_words': 41}