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

Must order bespoke-classes before bespoke-scale #56

Open
phdesign opened this issue May 22, 2015 · 2 comments
Open

Must order bespoke-classes before bespoke-scale #56

phdesign opened this issue May 22, 2015 · 2 comments

Comments

@phdesign
Copy link

When using the bower versions of bespoke plugins, the order of plugins becomes important. If you specify bespoke-scale before bespoke-classes scaling won't work. e.g.

bespoke.from('article', [
    bespoke.plugins.bullets('li, .bullet'),
    bespoke.plugins.backdrop(),
    bespoke.plugins.scale(),
    bespoke.plugins.hash(),
    bespoke.plugins.progress(),
    bespoke.plugins.classes(),
    bespoke.plugins.state(),
    bespoke.plugins.keys(),
    bespoke.plugins.touch()
]);

won't work but this will:

bespoke.from('article', [
    bespoke.plugins.classes(),
    bespoke.plugins.bullets('li, .bullet'),
    bespoke.plugins.backdrop(),
    bespoke.plugins.scale(),
    bespoke.plugins.hash(),
    bespoke.plugins.progress(),
    bespoke.plugins.state(),
    bespoke.plugins.keys(),
    bespoke.plugins.touch()
]);
@mojavelinux
Copy link
Contributor

The examples in the README show the plugins applied in the working order (i.e., classes() before all other plugins). Perhaps this point just needs to called out in the README (and perhaps in the description of the classes plugin).

It makes sense why this is the case. The classes plugin provides critical foundation that many other plugins rely on. In fact, in some ways, the classes plugin is an extension of core. I agree it should be a plugin in order to ensure maximum flexibility and reusability of bespoke.js, but it's reasonable to emphasize just how important this plugin is to the ecosystem.

@hsablonniere
Copy link
Member

+1 The documentation needs to explain that.

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

3 participants