Let’s create an example app that installs Fluidity from npm.
- Create an example app.
cd ~/Desktop
harp init example
cd example
-
Install normalize from npm
npm install fluidity -
Now you have two options. You can either keep everything in
node_modulesso it’s easy to update, or you can copy the stuff out you actually need. If you choose the former, you can add apackage.jsoninside_modules/node_modules/and still update the modules bycd-ing into_modules. You want the node_modules to be in an underscore directory as the Stylus will try and compile directly otherwise, and you don’t want each.stylpartial to be its own.cssfile. Without doing this, you will get an error onharp compile. -
Now, you can rename
main.lesstomain.styl. Insidemain.styl, add the following:
@import "_modules/node_modules/fluidity";