async-preloader
Advanced tools
Comparing version 3.2.0 to 3.3.0
{ | ||
"name": "async-preloader", | ||
"version": "3.2.0", | ||
"version": "3.3.0", | ||
"description": "Assets preloader using ES2017 async/await and fetch.", | ||
"main": "lib/async-preloader.js", | ||
"jsnext:main": "lib/async-preloader.module.js", | ||
"module": "lib/async-preloader.module.js", | ||
"main": "lib/async-preloader.cjs.js", | ||
"browser": "lib/async-preloader.umd.js", | ||
"module": "lib/async-preloader.esm.js", | ||
"jsnext:main": "lib/async-preloader.esm.js", | ||
"types": "lib/index.d.ts", | ||
@@ -26,9 +27,11 @@ "license": "MIT", | ||
"scripts": { | ||
"dev": "rollup -c -w -m inline", | ||
"dev": "rollup -c -w -m inline --environment NODE_ENV:development", | ||
"jest": "jest test/ --watch --coverage --no-cache", | ||
"clean": "rm -rf lib && rm -rf docs", | ||
"build": "rollup -c", | ||
"docs": "typedoc --out docs --mode modules --excludeExternals --includeDeclarations --module commonjs --theme default src && echo '' > docs/.nojekyll", | ||
"build": "rollup -c --environment NODE_ENV:production", | ||
"docs": "typedoc --out docs --mode modules --excludeExternals --includeDeclarations --module commonjs --theme default src", | ||
"test": "jest test/", | ||
"prepublishOnly": "npm run build && npm run docs" | ||
"preversion": "npm run clean && npm run test", | ||
"version": "npm run build && npm run docs && git add -A", | ||
"postversion": "git push && git push --tags && npm publish" | ||
}, | ||
@@ -68,4 +71,6 @@ "jest": { | ||
"rollup": "^0.56.3", | ||
"rollup-plugin-commonjs": "^9.1.3", | ||
"rollup-plugin-node-resolve": "^3.0.3", | ||
"rollup-plugin-typescript2": "^0.11.1", | ||
"rollup-plugin-uglify": "^4.0.0", | ||
"rollup-watch": "^4.3.1", | ||
@@ -78,3 +83,3 @@ "ts-jest": "^22.4.0", | ||
"dependencies": { | ||
"fontfaceobserver": "^2.0.13", | ||
"fontfaceobserver-es": "^3.2.0", | ||
"lodash-es": "^4.17.10", | ||
@@ -81,0 +86,0 @@ "tslib": "^1.9.0" |
import resolve from "rollup-plugin-node-resolve"; | ||
import commonjs from "rollup-plugin-commonjs"; | ||
import typescript from "rollup-plugin-typescript2"; | ||
import { uglify } from "rollup-plugin-uglify"; | ||
export default { | ||
input: "src/index.ts", | ||
plugins: [ | ||
resolve(), | ||
typescript({ | ||
typescript: require("typescript") | ||
}) | ||
], | ||
output: [ | ||
{ | ||
import pkg from "./package.json"; | ||
const isDev = process.env.NODE_ENV === "development"; | ||
export default [ | ||
{ | ||
input: "src/index.ts", | ||
plugins: [ | ||
resolve(), | ||
commonjs(), | ||
typescript({ | ||
typescript: require("typescript") | ||
}), | ||
isDev ? 0 : uglify() | ||
].filter(Boolean), | ||
external: ["tslib", "lodash-es/get", "fontfaceobserver-es"], | ||
output: { | ||
name: "AsyncPreloader", | ||
format: "umd", | ||
file: "lib/async-preloader.js", | ||
name: "AsyncPreloader", | ||
file: pkg.browser, | ||
exports: "named", | ||
globals: { | ||
tslib: "tslib", | ||
lodash: "lodash", | ||
fontfaceobserver: "FontFaceObserver" | ||
"lodash-es/get": "_.get", | ||
"fontfaceobserver-es": "FontFaceObserver" | ||
} | ||
}, | ||
{ | ||
} | ||
}, | ||
{ | ||
input: "src/index.ts", | ||
plugins: [ | ||
resolve(), | ||
commonjs(), | ||
typescript({ | ||
typescript: require("typescript") | ||
}), | ||
isDev ? 0 : uglify() | ||
].filter(Boolean), | ||
external: ["tslib", "lodash-es/get", "fontfaceobserver-es"], | ||
output: { | ||
format: "cjs", | ||
file: pkg.main, | ||
exports: "named" | ||
} | ||
}, | ||
{ | ||
input: "src/index.ts", | ||
plugins: [ | ||
resolve(), | ||
typescript({ | ||
typescript: require("typescript") | ||
}) | ||
], | ||
external: ["tslib", "lodash-es/get", "fontfaceobserver-es"], | ||
output: { | ||
format: "es", | ||
file: "lib/async-preloader.module.js" | ||
file: pkg.module | ||
} | ||
], | ||
external: ["tslib", "lodash", "fontfaceobserver"] | ||
}; | ||
} | ||
]; |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
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
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
12
50047
19
796
3
2
+ Addedfontfaceobserver-es@^3.2.0
+ Addedfontfaceobserver-es@3.3.3(transitive)
- Removedfontfaceobserver@^2.0.13
- Removedfontfaceobserver@2.3.0(transitive)