Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

awilix

Package Overview
Dependencies
Maintainers
1
Versions
92
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

awilix - npm Package Compare versions

Comparing version 7.0.3 to 8.0.0

lib/awilix.module.mjs

10

lib/awilix.browser.js

@@ -230,3 +230,3 @@ /******************************************************************************

var value = '';
var flags = 0 /* None */;
var flags = 0 /* TokenizerFlags.None */;
// These are used to greedily skip as much as possible.

@@ -244,3 +244,3 @@ // Whenever we reach a paren, we increment these.

function next(nextFlags) {
if (nextFlags === void 0) { nextFlags = 0 /* None */; }
if (nextFlags === void 0) { nextFlags = 0 /* TokenizerFlags.None */; }
flags = nextFlags;

@@ -283,3 +283,3 @@ advance();

pos++;
if ((flags & 1 /* Dumb */) === 0) {
if ((flags & 1 /* TokenizerFlags.Dumb */) === 0) {
// Not in dumb-mode, so attempt to skip.

@@ -696,3 +696,3 @@ skipExpression();

while (!isConstructorToken() && !done()) {
nextToken(1 /* Dumb */);
nextToken(1 /* TokenizerFlags.Dumb */);
}

@@ -711,3 +711,3 @@ }

function nextToken(flags) {
if (flags === void 0) { flags = 0 /* None */; }
if (flags === void 0) { flags = 0 /* TokenizerFlags.None */; }
t = _next(flags);

@@ -714,0 +714,0 @@ return t;

@@ -236,3 +236,3 @@ (function (global, factory) {

var value = '';
var flags = 0 /* None */;
var flags = 0 /* TokenizerFlags.None */;
// These are used to greedily skip as much as possible.

@@ -250,3 +250,3 @@ // Whenever we reach a paren, we increment these.

function next(nextFlags) {
if (nextFlags === void 0) { nextFlags = 0 /* None */; }
if (nextFlags === void 0) { nextFlags = 0 /* TokenizerFlags.None */; }
flags = nextFlags;

@@ -289,3 +289,3 @@ advance();

pos++;
if ((flags & 1 /* Dumb */) === 0) {
if ((flags & 1 /* TokenizerFlags.Dumb */) === 0) {
// Not in dumb-mode, so attempt to skip.

@@ -702,3 +702,3 @@ skipExpression();

while (!isConstructorToken() && !done()) {
nextToken(1 /* Dumb */);
nextToken(1 /* TokenizerFlags.Dumb */);
}

@@ -717,3 +717,3 @@ }

function nextToken(flags) {
if (flags === void 0) { flags = 0 /* None */; }
if (flags === void 0) { flags = 0 /* TokenizerFlags.None */; }
t = _next(flags);

@@ -1461,4 +1461,2 @@ return t;

Object.defineProperty(exports, '__esModule', { value: true });
}));

@@ -59,3 +59,3 @@ import { ResolutionStack } from './container';

*/
static assert<T>(condition: T, funcDescription: string, paramName: string, expectedType: string, givenType: any): T;
static assert<T>(condition: T, funcDescription: string, paramName: string, expectedType: string, givenType: any): NonNullable<T>;
}

@@ -62,0 +62,0 @@ /**

@@ -14,3 +14,3 @@ "use strict";

let value = '';
let flags = 0 /* None */;
let flags = 0 /* TokenizerFlags.None */;
// These are used to greedily skip as much as possible.

@@ -27,3 +27,3 @@ // Whenever we reach a paren, we increment these.

*/
function next(nextFlags = 0 /* None */) {
function next(nextFlags = 0 /* TokenizerFlags.None */) {
flags = nextFlags;

@@ -66,3 +66,3 @@ advance();

pos++;
if ((flags & 1 /* Dumb */) === 0) {
if ((flags & 1 /* TokenizerFlags.Dumb */) === 0) {
// Not in dumb-mode, so attempt to skip.

@@ -69,0 +69,0 @@ skipExpression();

@@ -103,3 +103,3 @@ "use strict";

while (!isConstructorToken() && !done()) {
nextToken(1 /* Dumb */);
nextToken(1 /* TokenizerFlags.Dumb */);
}

@@ -117,3 +117,3 @@ }

*/
function nextToken(flags = 0 /* None */) {
function nextToken(flags = 0 /* TokenizerFlags.None */) {
t = _next(flags);

@@ -120,0 +120,0 @@ return t;

{
"name": "awilix",
"version": "7.0.3",
"version": "8.0.0",
"description": "Extremely powerful dependency injection container.",
"main": "lib/awilix.js",
"module": "lib/awilix.module.js",
"jsnext:main": "lib/awilix.module.js",
"module": "lib/awilix.module.mjs",
"jsnext:main": "lib/awilix.module.mjs",
"browser": "lib/awilix.browser.js",

@@ -53,17 +53,17 @@ "umd:main": "lib/awilix.umd.js",

"devDependencies": {
"@babel/core": "^7.17.10",
"@babel/plugin-transform-runtime": "^7.17.10",
"@babel/preset-env": "^7.17.10",
"@babel/runtime": "^7.17.9",
"@types/jest": "^27.4.1",
"@types/node": "^17.0.31",
"babel-jest": "^28.0.3",
"@babel/core": "^7.19.3",
"@babel/plugin-transform-runtime": "^7.19.1",
"@babel/preset-env": "^7.19.4",
"@babel/runtime": "^7.19.4",
"@types/jest": "^29.1.2",
"@types/node": "^18.8.5",
"babel-jest": "^29.2.0",
"coveralls": "^3.1.1",
"husky": "^7.0.4",
"husky": "^8.0.1",
"istanbul": "^0.4.5",
"jest": "^28.0.3",
"lint-staged": "^12.4.1",
"prettier": "^2.6.2",
"jest": "^29.2.0",
"lint-staged": "^13.0.3",
"prettier": "^2.7.1",
"rimraf": "^3.0.2",
"rollup": "^2.71.1",
"rollup": "^3.1.0",
"rollup-plugin-commonjs": "^10.1.0",

@@ -73,5 +73,5 @@ "rollup-plugin-copy": "^3.4.0",

"rollup-plugin-replace": "^2.2.0",
"rollup-plugin-typescript2": "^0.31.2",
"rollup-plugin-typescript2": "^0.34.1",
"smid": "^0.1.1",
"ts-jest": "^28.0.0-next.3",
"ts-jest": "^29.0.3",
"tslib": "^2.4.0",

@@ -81,7 +81,7 @@ "tslint": "^6.1.3",

"tslint-config-standard": "^9.0.0",
"typescript": "^4.6.4"
"typescript": "^4.8.4"
},
"dependencies": {
"camel-case": "^4.1.2",
"fast-glob": "^3.2.11"
"fast-glob": "^3.2.12"
},

@@ -104,3 +104,3 @@ "lint-staged": {

"targets": {
"node": "12.0.0"
"node": "14.0.0"
}

@@ -139,6 +139,11 @@ }

"transform": {
"^.+\\.tsx?$": "ts-jest",
"^.+\\.jsx?$": "babel-jest"
"^.+\\.tsx?$": [
"ts-jest",
{
"useESM": true
}
],
"^.+\\.m?jsx?$": "babel-jest"
}
}
}

@@ -1055,2 +1055,4 @@ # Awilix

> 💡 When using `opts.esModules`, a `Promise` is returned due to using the asynchronous `import()`.
Awilix will use `require` on the loaded modules, and register the

@@ -1072,4 +1074,6 @@ default-exported function or class as the name of the file.

the lifetime, injection mode and more of the loaded modules.
- `opts.esModules`: Loads modules using Node's native ES modules. This is only
supported on Node 14.0+ and should only be used if you're using the [Native Node ES modules](https://nodejs.org/api/esm.html)
- `opts.esModules`: Loads modules using Node's native ES modules.
**This makes `container.loadModules` asynchronous, and will therefore return a `Promise`!**
This is only supported on Node 14.0+ and should only be used if you're using
the [Native Node ES modules](https://nodejs.org/api/esm.html)

@@ -1136,4 +1140,4 @@ Example:

**Important**: `loadModules` depends on `glob` and is therefore not supported in
module bundlers like Webpack, Rollup and Browserify.
**Important**: `loadModules` depends on `fast-glob` and is therefore not supported in
module bundlers like Webpack, Rollup, esbuild and Browserify.

@@ -1327,3 +1331,3 @@ ### `container.createScope()`

- CommonJS, the good ol' Node format - `lib/awilix.js`
- ES Modules, for use with module bundlers **in Node** - `lib/awilix.module.js`
- ES Modules, for use with module bundlers **in Node** - `lib/awilix.module.mjs`
- ES Modules, for use with module bundlers **in the browser** -

@@ -1330,0 +1334,0 @@ `lib/awilix.browser.js`

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc