Reputation: 4200
Given that we're living in a post Meteor 1.0 world, is it "better" to use the meteor package nemo64:bootstrap or to install the bower (meteor package) and then manage bootstrap as a bower dependency?
I feel like if I were going to start from frontend scratch I would use nemo64:bootstrap, but if I have a prepackaged frontend with a million packages loaded up already, with working dependency trees, I should manage dependencies through bower?
Using the mquandalle (https://github.com/mquandalle/meteor-bower) package to minify all my bower assets, it re-installs jquery! Doubling up on that can't be good!
Upvotes: 1
Views: 248
Reputation: 4200
The particular situation I was concerned with was 'porting' a pre-designed template to meteor.
I settled on twbs:bootstrap
because it was a one step addition; meteor add twbs:bootstrap
can be done and undone easily (in source control)! Bootstrap also guarantees it because its official, and load order is sorted!!
To deal with all the bower dependencies, I just included them in the head, and then used
Template.sidebar.rendered = function() {
// ..initialise all the libraries here
}
Which has the luckiest feature of only initialising the libraries when the actual template is loaded!!! Yay
I think you can even use miro:preloaded
or equivalent to conditionally load those js libraries (rather than using /public
and serving static js assets from <head>
)
Upvotes: 0
Reputation: 430
Our company has begun converting some of our bower dependencies to Meteor packages. We do this because you can not publish your own Meteor packages if they require bower dependencies.
Sidenote: We use nemo64:bootstrap and it works very well for us.
Upvotes: 0