fbrctr / fabricator

A tool for building website UI toolkits and style guides
http://fbrctr.github.io/
MIT License
1.11k stars 124 forks source link

Thousands of lines added to toolkit.js #293

Closed labar closed 7 years ago

labar commented 7 years ago

First of all I wanted to say thank you for this amazing thing you have created! I really appreciate all the hard work put into this project.

The issue I am having is with the toolkit.js file. Originally my js file was 386 lines of code. When I look at the compiled version in the dist folder it's up over 10,000 lines.

I have tried searching google for answers and looked through the issues already posted here and could not locate anything that helped.

Any help you could offer would be super appreciated!

toolkit.js.zip

Thanks again! David LaBar

PierreGUI commented 7 years ago

Your JS file is being bundled with jQuery. Since fabricator uses webpack to prepare your toolkit.js and it seems to be a link to jquery dependency in the latter, the whole library gets included in your bundle.

If you don't want jquery in your toolkit, try importing it from somewhere else (or manually add it to your window object, eg: script tag in your home html).

labar commented 7 years ago

Thanks a lot my friend! I figured it was something dumb that I did. I was having trouble getting jquery to work when I first setup Fabricator so I ended up doing the require jquery. I appreciate your time!