Closed dvlden closed 8 years ago
Hi dvLden, the main reason for injecting the css is that it's very convenient to use with browserify for example. And it's only a bit more than 60 lines of css, so it doesn't have a big impact on the size. Would overwriting the styles be an option for you?
I simply commented out that require()
of CSS at the top of your script and it seem to have no problems at all.
Are you using browserify or some other module loader? If yes you can probably just exclude the css in the build options.
Yes, I am using Browserify. I'll check that one out (Y)
Using webpack here but did the same thing, commented out the require. I could extract it to a bundle but I want all my CSS in one place.
Not sure about webpack, but I know with browserify there's an exclude option to skip modules that are not supposed to be in the build. Let me know if that works for you.
👍 Closing this for now, feel free to reopen if excluding doesn't work.
I see that your script automatically adds/injects the CSS, tho I'd like to write my SASS styling that I can reuse with ease for other projects with your module.
Is it possible that you make this as option, such as:
Although you could also simply separate styling from JS and don't inject it at all. If there's a workaround let me know.