Code Monkey home page Code Monkey logo

Comments (3)

diegonetto avatar diegonetto commented on September 25, 2024

Thanks Jens!

When you install bower components are you using bower install --save-dev (this will updated your bower.json file) ?

The bower-install task in our Gruntfile will inject your dependencies inside the bower:css (https://github.com/diegonetto/generator-ionic/blob/master/templates/views/index.html#L14) and bower:js (https://github.com/diegonetto/generator-ionic/blob/master/templates/views/index.html#L40) usemin blocks.

As for the vendor files, you need to manually add any CSS and JS files inside the usemin build blocks but outside the bower blocks (since bower will overwrite that section).

If you look at the lines linked above you should see comments for where exactly to put your external vendor assets not managed by bower. If you properly set up your assets inside the usemin blocks, the build process will be able to handle your vendor files properly.

from generator-ionic.

morenoh149 avatar morenoh149 commented on September 25, 2024

Would be useful if there were docs showing how to use bower like this. I know for myself, this was one of the first yeoman generators I've ever used. So I was completely lost as to using bower install --save-dev to update bower.json. I thought bower install and manually adding the dep in index.html was the right way, but would get destroy by grunt.

from generator-ionic.

diegonetto avatar diegonetto commented on September 25, 2024

Bower's bower.json follows similar conventions to Node's package.json. Bower isn't tied to Yeoman, but if this was your first exposure to Bower then great! Its awesome for managing front-end libraries as packages.

I'll include a section in the docs that mention this in order to assist newcomers.

from generator-ionic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.