sheerun / bower-away

A tool for migrating away from Bower (to Yarn)
307 stars 21 forks source link

How can I add to new bower component now with yarn. #19

Open srikanthdarmapuri opened 7 years ago

srikanthdarmapuri commented 7 years ago

I would like to add new bower component inside node_modules/@bower_components. How can achieve that. If do "yarn add ", it is added directly in node_modules/

ahbarrios commented 6 years ago

I have the same problem any help, please!

Stefdv commented 6 years ago

Shouldn't you use yarn add --flat <package_name> then ?

sheerun commented 6 years ago

e.g. if you want to add jquery then do:

bower lookup jquery
jquery https://github.com/jquery/jquery-dist.git

and:

yarn add @bower_components/jquery@jquery/jquery-dist

But really, you should consider adding new components from npm's registry (i.e. yarn add jquery), and employing webpack to bundle them (const $ = require('jquery')).

--flat is not necessary

Stefdv commented 6 years ago

I'm using Polymer...Until Polymer 3 is released i'm stuck on bower :( And creating a fork of all components seems a little overhead

sheerun commented 6 years ago

You don't need to fork anything. Yarn can install any github repository.