Skip to content

Commit

Permalink
fixed "main" entry in bower.json, fixed AMD and CommonJS definitions …
Browse files Browse the repository at this point in the history
…to correctly require dependencies
  • Loading branch information
FM committed May 28, 2015
1 parent e9f1cca commit 82504aa
Show file tree
Hide file tree
Showing 7 changed files with 43 additions and 25 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"Paolo Scanferla <[email protected]>"
],
"description": "A lightweight and flexible alternative to Meteor's client-side framework",
"main": "dist/asteroid.js",
"main": "dist/asteroid.browser.js",
"moduleType": [
"amd",
"globals",
Expand Down
11 changes: 7 additions & 4 deletions dist/asteroid.browser.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";

Expand Down
11 changes: 7 additions & 4 deletions dist/asteroid.chrome.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";

Expand Down
11 changes: 7 additions & 4 deletions dist/asteroid.cordova.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";

Expand Down
11 changes: 7 additions & 4 deletions src/platforms/browser/wrapper/head.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";
11 changes: 7 additions & 4 deletions src/platforms/chrome/wrapper/head.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";
11 changes: 7 additions & 4 deletions src/platforms/cordova/wrapper/head.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
(function (root, factory) {
if (typeof define === "function" && define.amd) {
define(factory);
define(['ddp.js', 'q'], factory);
} else if (typeof exports === "object") {
module.exports = factory();
var DDP = require('ddp.js');
var Q = require('q');

module.exports = factory(DDP, Q);
} else {
root.Asteroid = factory();
root.Asteroid = factory(root.DDP, root.Q);
}
}(this, function () {
}(this, function (DDP, Q) {

"use strict";

0 comments on commit 82504aa

Please sign in to comment.