Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Options in collection method? #23

Closed
aendra-rininsland opened this issue May 16, 2014 · 9 comments
Closed

Options in collection method? #23

aendra-rininsland opened this issue May 16, 2014 · 9 comments

Comments

@aendra-rininsland
Copy link

Hi!
The generator scaffolds out a collection method, a static method, default options for the static method and a custom selector. In order to use the static method's default options in the collection method, I'm guessing I'd pass an options argument and then do options = $.extend({}, $.myplugin.options, options); like is done in the static method?

If so, this should maybe be clarified (or options passed to the collection method as they're currently done to the static method). I'm not a total neophyte in terms of writing jQuery plugins, but I found the scaffolded code confusing enough to stop me for a moment...

@sindresorhus
Copy link
Member

@zenorocha

@zenorocha
Copy link
Member

I vote for this discussion to be moved to grunt-init-jquery since this generator was built based on it.

@aendra-rininsland
Copy link
Author

@zenorocha Makes sense. Should I create a new issue there, then? Thanks!

@zenorocha
Copy link
Member

yep ;)

@sindresorhus
Copy link
Member

No, let's keep the discussion here. grunt-init is effectively unmaintained and nothing will come out of discussing there.

@arthurvr
Copy link
Member

The generator scaffolds out a collection method, a static method, default options for the static method and a custom selector.

As of #39, that's not really true anymore.

@aendra-rininsland
Copy link
Author

@arthurvr I haven't used this generator in awhile; your PR looks totally like what I was wanting though. Can I effectively close this issue then?

@arthurvr
Copy link
Member

If I am not understanding you wrong, yup!

@aendra-rininsland
Copy link
Author

Awesome, thanks! 😄 :shipit:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants