A powerful dependency injection micro container for JavaScript applications
v2.0.0 This version updates several dev dependencies to resolve security vulnerabilities, (thanks @dependabot-bot !)
It also adds a new ES module build, available in the /dist directory. This is a possible breaking change for some webpack users, so the major version has been bumped to 2. Most users can migrate to bottlejs 2.0.0 without any backwards compatibility problems. Thanks, @blikblum !
This release updates the dev dependencies to resolve security vulnerabilities in the testing pipeline. It also updates the typescript file to support limiting / type checking entry names: https://github.com/young-steveo/bottlejs/pull/115 (thanks @ethanresnick )
Bottle does not have any dependencies.
However, a security vulnerability was discovered in one of Bottle's build and testing tools. This version of BottleJS updates all of Bottle's dev tools to their latest versions and recompiles the minified source to alleviate any security concerns.
The only noticeable change is an improved file size from the minification library that BotteJS uses (the minified file is about 30 bytes smaller. 🤣)
serviceFactory
method #104Fixes a bug with resetProviders
when using nested containers. Nested containers will no longer break when they have multiple children.
This patch release adds better support for classes in the typescript definition file, and fixes a bug with registering new services on an already-instantiated nested container ( thanks to @aretmy and @TimWolla ).
bottle.resetProviders()
. This is primarily useful for unit testing. @cjsaylor$decorator
function that will only add decorators to that container's services. This is useful for nested bottles. @iMosesBottle.pop
and Bottle.clear
have been updated to allow empty strings to name and clear a bottle. Any string value is now valid. @Coburn37Bottle.clear
. - thanks, @emilong$list
method definition.instanceFactory
- thanks @nzack