Comparing version 0.1.10 to 0.1.11
@@ -142,7 +142,9 @@ //------------------------------------------------------------------------------- | ||
BugPackSourceProcessor.prototype.processingComplete = function(error) { | ||
this.processed = true; | ||
this.processedCallbacks.forEach(function(processedCallback) { | ||
processedCallback(error); | ||
}); | ||
this.processedCallbacks = []; | ||
if (!this.processed) { | ||
this.processed = true; | ||
this.processedCallbacks.forEach(function (processedCallback) { | ||
processedCallback(error); | ||
}); | ||
this.processedCallbacks = []; | ||
} | ||
}; | ||
@@ -167,3 +169,3 @@ | ||
} else { | ||
callback(error); | ||
_this.processingComplete(error); | ||
} | ||
@@ -170,0 +172,0 @@ }); |
{ | ||
"name": "bugpack", | ||
"version": "0.1.10", | ||
"version": "0.1.11", | ||
"description": "Package loader to help make browser and node js package loading consistent", | ||
@@ -5,0 +5,0 @@ "main": "./lib/BugPackApi.js", |
@@ -14,1 +14,56 @@ # bugpack | ||
to offer. If the library is missing something you need, please let us know! | ||
Latest Version `0.1.11` | ||
## Quick Examples | ||
Export and require without loading of registry | ||
```javascript | ||
var bugpack = require('bugpack'); | ||
var MyExport = function() {}; | ||
bugpack.export('MyExportName', MyExport); | ||
// Else where in code... | ||
var MyExport = bugpack.require('MyExportName'); // MyExport | ||
``` | ||
## Download | ||
The source is available for download from [GitHub](https://github.com/airbug/bugpack) | ||
For node js, you can install using Node Package Manager [npm](https://www.npmjs.org/package/bugpack) | ||
npm install bugpack | ||
For the web, you can access the scripts here | ||
https://s3.amazonaws.com/public-airbug/bugpack-0.1.11.js | ||
https://s3.amazonaws.com/public-airbug/bugpack-0.1.11.min.js | ||
## Usage | ||
In node js: | ||
```javascript | ||
var bugpack = require('bugpack'); | ||
var SomePackage = bugpack.require('SomePackage'); | ||
``` | ||
In the browser: | ||
```html | ||
<script type="text/javascript" src="https://s3.amazonaws.com/public-airbug/bugpack-0.1.11.js"></script> | ||
<script type="text/javascript"> | ||
var bugpack = require('bugpack'); | ||
var SomePackage = bugpack.require('SomePackage'); | ||
</script> | ||
``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
64983
1862
69