mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
This implies that all exports are package variables, which made underscore, jquery, and htmljs (which explicitly assigned to fields on the global variable) break. We now properly encapsulate these packages (except for window.jQuery, which we let sneak out because bootstrap wants it). This means that packages that want _ need to use underscore, and packages that want $ need to use jquery. Also, you can't use _ in minimongo $where any more (matching mongod).
25 lines
1.0 KiB
JavaScript
25 lines
1.0 KiB
JavaScript
Package.describe({
|
|
summary: "Collection of small helper functions: _.map, _.each, ..."
|
|
});
|
|
|
|
Package.on_use(function (api) {
|
|
// Like all packages, we have an implicit depedency on the 'meteor'
|
|
// package, which provides such things as the *.js file handler. Use
|
|
// an undocumented API to allow 'meteor' to after us even though we
|
|
// depend on it. This is necessary since 'meteor' depends on us. One
|
|
// day we will avoid this problem by refactor, but for now this is a
|
|
// practical and expedient solution.
|
|
//
|
|
// XXX Now the *.js handler is intrinsic rather than coming from the
|
|
// 'meteor' package and we could remove this (if we provided a way
|
|
// to let the package opt to not depend on 'meteor'.) We could even
|
|
// remove unordered dependency support, though I think it's worth keeping
|
|
// around for now to keep the possibility of dependency
|
|
// configuration alive in the codebase.
|
|
api.use('meteor', {unordered: true});
|
|
|
|
api.exportSymbol('_');
|
|
|
|
api.add_files(['pre.js', 'underscore.js', 'post.js']);
|
|
});
|