[WIP] Make Chosen more extendable #1647

Open
wants to merge 4 commits into from

6 participants

@koenpunt

After keeping my PR for option adding (#166) up to date for over 2 years I got a suggestion from @mculp: koenpunt/chosen#38.

And by extracting more code into separate methods extending Chosen should become a breeze.

@stof stof commented on the diff Nov 8, 2013
coffee/chosen.jquery.coffee
@@ -195,6 +190,14 @@ class Chosen extends AbstractChosen
@parsing = false
+ single_set_nosearch: ->
@stof
stof added a note Nov 8, 2013

you should extract it in the Prototype version too, to stay consistent

@koenpunt
koenpunt added a note Nov 8, 2013

You're right! Would've come to that when testing extending the prototype version. For now will mark this WIP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@lephyrius

👍
This would simplify a lot of things.

@davereid

👍 This would be great to have official support for the new option code @koenpunt is working on without having to use a separate fork.

@pfiller

A more modularized Chosen would let us build on things like AJAX searching or option adding without polluting the base functionality. I'm 100% in support of this general idea and this seems like a good first step. @koenpunt what else do you think needs to happen here before it's useful to you?

@mculp

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment