add banner

This commit is contained in:
Rene Haas
2022-08-02 12:20:33 +02:00
parent 75b1df4307
commit 7720ca0a1b
14 changed files with 383 additions and 24 deletions
+3
View File
@@ -62,6 +62,7 @@ const mergeAndResolveOptions = (userOptions) => {
extractStyles: defaultExtractStyles,
extractTypes: defaultExtractTypes,
verbose: defaultVerbose,
banner: defaultBanner,
} = defaultOptions;
const {
project,
@@ -73,6 +74,7 @@ const mergeAndResolveOptions = (userOptions) => {
extractStyles: rawExtractStyles,
extractTypes: rawExtractTypes,
verbose: rawVerbose,
banner: rawBanner,
} = userOptions;
const projectPath = process.cwd();
const mergedOptions = {
@@ -82,6 +84,7 @@ const mergeAndResolveOptions = (userOptions) => {
extractStyles: rawExtractStyles ?? defaultExtractStyles,
extractTypes: rawExtractTypes ?? defaultExtractTypes,
verbose: rawVerbose ?? defaultVerbose,
banner: rawBanner ?? defaultBanner,
paths: {
...defaultPaths,
...rawPaths,
+1
View File
@@ -2,6 +2,7 @@ module.exports = {
project: null,
mode: 'build',
verbose: false,
banner: null,
paths: {
src: './src',
dist: './dist',
+3 -1
View File
@@ -7,6 +7,7 @@ const {
rollupResolve,
rollupAlias,
rollupScss,
rollupLicense,
} = require('./pipeline.common.plugins');
const createOutputWithMinifiedVersion = (output, esm, buildMinifiedVersion) =>
@@ -36,7 +37,7 @@ const createOutputWithMinifiedVersion = (output, esm, buildMinifiedVersion) =>
);
module.exports = (resolve, options, esm) => {
const { rollup, paths, versions, alias, extractStyles } = options;
const { rollup, paths, versions, alias, extractStyles, banner } = options;
const { output: rollupOutput, input, plugins = [], ...rollupOptions } = rollup;
const { name, file, globals, exports, sourcemap: rawSourcemap, ...outputConfig } = rollupOutput;
const { minified: buildMinifiedVersion } = versions;
@@ -75,6 +76,7 @@ module.exports = (resolve, options, esm) => {
rollupResolve(srcPath, resolve),
rollupCommonjs(sourcemap, resolve),
rollupBabel(resolve, esm),
rollupLicense(banner, sourcemap),
...plugins,
].filter(Boolean),
};
@@ -9,6 +9,7 @@ const rollupPluginCommonjs = require('@rollup/plugin-commonjs');
const rollupPluginAlias = require('@rollup/plugin-alias');
const rollupPluginTs = require('rollup-plugin-typescript2');
const { default: rollupPluginEsBuild } = require('rollup-plugin-esbuild');
const rollupPluginLicense = require('rollup-plugin-license');
const babelConfigUmd = require('./babel.config.umd');
const babelConfigEsm = require('./babel.config.esm');
@@ -97,4 +98,13 @@ module.exports = {
include: ['*.ts+(|x)', '**/*.ts+(|x)'],
exclude: ['node_modules', '**/node_modules/*', '*.d.ts', '**/*.d.ts'],
}),
rollupLicense: (content, sourceMap) =>
content &&
rollupPluginLicense({
sourcemap: sourceMap,
banner: {
content,
commentStyle: 'ignored',
},
}),
};
@@ -30,6 +30,7 @@ module.exports = (testDir, mode = 'dev', onListening = null) => {
return createRollupConfig({
project: name,
mode,
banner: `${testDir}`,
paths: {
dist,
src: path.resolve(testDir, './'),
+312 -16
View File
@@ -7,9 +7,6 @@
"workspaces": [
"packages/*"
],
"dependencies": {
"rollup-plugin-typescript2": "^0.32.1"
},
"bin": {
"workspace-root": "workspace.root.js"
},
@@ -68,12 +65,14 @@
"rollup-plugin-dts": "^4.2.2",
"rollup-plugin-esbuild": "^4.9.1",
"rollup-plugin-ignore-import": "^1.3.2",
"rollup-plugin-license": "^2.8.1",
"rollup-plugin-livereload": "^2.0.0",
"rollup-plugin-scss": "^3.0.0",
"rollup-plugin-serve": "^1.1.0",
"rollup-plugin-styles": "^4.0.0",
"rollup-plugin-summary": "^1.4.3",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.32.1",
"sass": "^1.54.0",
"should": "^13.2.3",
"tslib": "^2.4.0",
@@ -3082,6 +3081,15 @@
"node": ">=6.0"
}
},
"node_modules/array-find-index": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz",
"integrity": "sha512-M1HQyIXcBGtVywBt8WVdim+lrNaK7VHp99Qt5pSNziXznKHViIBbXWtfRTpEFpF/c4FdfxNAsCCwPp5phBYJtw==",
"dev": true,
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/array-includes": {
"version": "3.1.5",
"dev": true,
@@ -3695,8 +3703,15 @@
"dev": true,
"license": "MIT"
},
"node_modules/commenting": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/commenting/-/commenting-1.1.0.tgz",
"integrity": "sha512-YeNK4tavZwtH7jEgK1ZINXzLKm6DZdEMfsaaieOsCAN0S8vsY7UeuO3Q7d/M018EFgE+IeUAuBOKkFccBZsUZA==",
"dev": true
},
"node_modules/commondir": {
"version": "1.0.1",
"dev": true,
"license": "MIT"
},
"node_modules/concat-map": {
@@ -5064,6 +5079,7 @@
},
"node_modules/estree-walker": {
"version": "2.0.2",
"dev": true,
"license": "MIT"
},
"node_modules/esutils": {
@@ -5222,6 +5238,7 @@
},
"node_modules/find-cache-dir": {
"version": "3.3.2",
"dev": true,
"license": "MIT",
"dependencies": {
"commondir": "^1.0.1",
@@ -5237,6 +5254,7 @@
},
"node_modules/find-up": {
"version": "4.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"locate-path": "^5.0.0",
@@ -5321,6 +5339,7 @@
},
"node_modules/fs-extra": {
"version": "10.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"graceful-fs": "^4.2.0",
@@ -5349,6 +5368,7 @@
},
"node_modules/function-bind": {
"version": "1.1.1",
"dev": true,
"license": "MIT"
},
"node_modules/function.prototype.name": {
@@ -5522,6 +5542,7 @@
},
"node_modules/graceful-fs": {
"version": "4.2.10",
"dev": true,
"license": "ISC"
},
"node_modules/gzip-size": {
@@ -5545,6 +5566,7 @@
},
"node_modules/has": {
"version": "1.0.3",
"dev": true,
"license": "MIT",
"dependencies": {
"function-bind": "^1.1.1"
@@ -5855,6 +5877,7 @@
},
"node_modules/is-core-module": {
"version": "2.9.0",
"dev": true,
"license": "MIT",
"dependencies": {
"has": "^1.0.3"
@@ -7258,6 +7281,7 @@
},
"node_modules/jsonfile": {
"version": "6.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"universalify": "^2.0.0"
@@ -7356,6 +7380,7 @@
},
"node_modules/locate-path": {
"version": "5.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"p-locate": "^4.1.0"
@@ -7434,6 +7459,7 @@
},
"node_modules/make-dir": {
"version": "3.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"semver": "^6.0.0"
@@ -7582,6 +7608,15 @@
"node": ">=10"
}
},
"node_modules/moment": {
"version": "2.29.4",
"resolved": "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz",
"integrity": "sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==",
"dev": true,
"engines": {
"node": "*"
}
},
"node_modules/ms": {
"version": "2.1.2",
"dev": true,
@@ -8034,6 +8069,7 @@
},
"node_modules/p-limit": {
"version": "2.3.0",
"dev": true,
"license": "MIT",
"dependencies": {
"p-try": "^2.0.0"
@@ -8047,6 +8083,7 @@
},
"node_modules/p-locate": {
"version": "4.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"p-limit": "^2.2.0"
@@ -8094,6 +8131,7 @@
},
"node_modules/p-try": {
"version": "2.2.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
@@ -8113,6 +8151,18 @@
"node": ">=8"
}
},
"node_modules/package-name-regex": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/package-name-regex/-/package-name-regex-2.0.6.tgz",
"integrity": "sha512-gFL35q7kbE/zBaPA3UKhp2vSzcPYx2ecbYuwv1ucE9Il6IIgBDweBlH8D68UFGZic2MkllKa2KHCfC1IQBQUYA==",
"dev": true,
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/dword-design"
}
},
"node_modules/parent-module": {
"version": "1.0.1",
"dev": true,
@@ -8148,6 +8198,7 @@
},
"node_modules/path-exists": {
"version": "4.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -8171,6 +8222,7 @@
},
"node_modules/path-parse": {
"version": "1.0.7",
"dev": true,
"license": "MIT"
},
"node_modules/path-type": {
@@ -8188,6 +8240,7 @@
},
"node_modules/picomatch": {
"version": "2.3.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8.6"
@@ -8206,6 +8259,7 @@
},
"node_modules/pkg-dir": {
"version": "4.2.0",
"dev": true,
"license": "MIT",
"dependencies": {
"find-up": "^4.0.0"
@@ -9073,6 +9127,7 @@
},
"node_modules/resolve": {
"version": "1.22.1",
"dev": true,
"license": "MIT",
"dependencies": {
"is-core-module": "^2.9.0",
@@ -9138,6 +9193,7 @@
},
"node_modules/rollup": {
"version": "2.75.7",
"dev": true,
"license": "MIT",
"bin": {
"rollup": "dist/bin/rollup"
@@ -9223,6 +9279,41 @@
"rollup-pluginutils": "^2.8.2"
}
},
"node_modules/rollup-plugin-license": {
"version": "2.8.1",
"resolved": "https://registry.npmjs.org/rollup-plugin-license/-/rollup-plugin-license-2.8.1.tgz",
"integrity": "sha512-VYd9pzaNL7NN6xQp93XiiCV2UoduXgSmTcz6rl9bHPdiifT6yH3Zw/omEr73Rq8TIyN4nqJACBbKIT/2eE66wg==",
"dev": true,
"dependencies": {
"commenting": "~1.1.0",
"glob": "~7.2.0",
"lodash": "~4.17.21",
"magic-string": "~0.26.2",
"mkdirp": "~1.0.4",
"moment": "~2.29.3",
"package-name-regex": "~2.0.6",
"spdx-expression-validate": "~2.0.0",
"spdx-satisfies": "~5.0.1"
},
"engines": {
"node": ">=10.0.0"
},
"peerDependencies": {
"rollup": "^1.0.0 || ^2.0.0"
}
},
"node_modules/rollup-plugin-license/node_modules/magic-string": {
"version": "0.26.2",
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.26.2.tgz",
"integrity": "sha512-NzzlXpclt5zAbmo6h6jNc8zl2gNRGHvmsZW4IvZhTC4W7k4OlLP+S5YLussa/r3ixNT66KOQfNORlXHSOy/X4A==",
"dev": true,
"dependencies": {
"sourcemap-codec": "^1.4.8"
},
"engines": {
"node": ">=12"
}
},
"node_modules/rollup-plugin-livereload": {
"version": "2.0.5",
"dev": true,
@@ -9343,6 +9434,7 @@
"version": "0.32.1",
"resolved": "https://registry.npmjs.org/rollup-plugin-typescript2/-/rollup-plugin-typescript2-0.32.1.tgz",
"integrity": "sha512-RanO8bp1WbeMv0bVlgcbsFNCn+Y3rX7wF97SQLDxf0fMLsg0B/QFF005t4AsGUcDgF3aKJHoqt4JF2xVaABeKw==",
"dev": true,
"dependencies": {
"@rollup/pluginutils": "^4.1.2",
"find-cache-dir": "^3.3.2",
@@ -9359,6 +9451,7 @@
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-4.2.1.tgz",
"integrity": "sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ==",
"dev": true,
"dependencies": {
"estree-walker": "^2.0.1",
"picomatch": "^2.2.2"
@@ -9442,6 +9535,7 @@
},
"node_modules/semver": {
"version": "6.3.0",
"dev": true,
"license": "ISC",
"bin": {
"semver": "bin/semver.js"
@@ -9633,6 +9727,65 @@
"node": ">=8"
}
},
"node_modules/spdx-compare": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/spdx-compare/-/spdx-compare-1.0.0.tgz",
"integrity": "sha512-C1mDZOX0hnu0ep9dfmuoi03+eOdDoz2yvK79RxbcrVEG1NO1Ph35yW102DHWKN4pk80nwCgeMmSY5L25VE4D9A==",
"dev": true,
"dependencies": {
"array-find-index": "^1.0.2",
"spdx-expression-parse": "^3.0.0",
"spdx-ranges": "^2.0.0"
}
},
"node_modules/spdx-exceptions": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz",
"integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==",
"dev": true
},
"node_modules/spdx-expression-parse": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz",
"integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==",
"dev": true,
"dependencies": {
"spdx-exceptions": "^2.1.0",
"spdx-license-ids": "^3.0.0"
}
},
"node_modules/spdx-expression-validate": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/spdx-expression-validate/-/spdx-expression-validate-2.0.0.tgz",
"integrity": "sha512-b3wydZLM+Tc6CFvaRDBOF9d76oGIHNCLYFeHbftFXUWjnfZWganmDmvtM5sm1cRwJc/VDBMLyGGrsLFd1vOxbg==",
"dev": true,
"dependencies": {
"spdx-expression-parse": "^3.0.0"
}
},
"node_modules/spdx-license-ids": {
"version": "3.0.11",
"resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.11.tgz",
"integrity": "sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==",
"dev": true
},
"node_modules/spdx-ranges": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/spdx-ranges/-/spdx-ranges-2.1.1.tgz",
"integrity": "sha512-mcdpQFV7UDAgLpXEE/jOMqvK4LBoO0uTQg0uvXUewmEFhpiZx5yJSZITHB8w1ZahKdhfZqP5GPEOKLyEq5p8XA==",
"dev": true
},
"node_modules/spdx-satisfies": {
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/spdx-satisfies/-/spdx-satisfies-5.0.1.tgz",
"integrity": "sha512-Nwor6W6gzFp8XX4neaKQ7ChV4wmpSh2sSDemMFSzHxpTw460jxFYeOn+jq4ybnSSw/5sc3pjka9MQPouksQNpw==",
"dev": true,
"dependencies": {
"spdx-compare": "^1.0.0",
"spdx-expression-parse": "^3.0.0",
"spdx-ranges": "^2.0.0"
}
},
"node_modules/split-on-first": {
"version": "1.1.0",
"dev": true,
@@ -9857,6 +10010,7 @@
},
"node_modules/supports-preserve-symlinks-flag": {
"version": "1.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.4"
@@ -10052,6 +10206,7 @@
},
"node_modules/tslib": {
"version": "2.4.0",
"dev": true,
"license": "0BSD"
},
"node_modules/tsutils": {
@@ -10113,6 +10268,7 @@
},
"node_modules/typescript": {
"version": "4.7.4",
"dev": true,
"license": "Apache-2.0",
"bin": {
"tsc": "bin/tsc",
@@ -10174,6 +10330,7 @@
},
"node_modules/universalify": {
"version": "2.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 10.0.0"
@@ -12415,6 +12572,12 @@
"@babel/runtime-corejs3": "^7.10.2"
}
},
"array-find-index": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz",
"integrity": "sha512-M1HQyIXcBGtVywBt8WVdim+lrNaK7VHp99Qt5pSNziXznKHViIBbXWtfRTpEFpF/c4FdfxNAsCCwPp5phBYJtw==",
"dev": true
},
"array-includes": {
"version": "3.1.5",
"dev": true,
@@ -12797,8 +12960,15 @@
"version": "2.20.3",
"dev": true
},
"commenting": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/commenting/-/commenting-1.1.0.tgz",
"integrity": "sha512-YeNK4tavZwtH7jEgK1ZINXzLKm6DZdEMfsaaieOsCAN0S8vsY7UeuO3Q7d/M018EFgE+IeUAuBOKkFccBZsUZA==",
"dev": true
},
"commondir": {
"version": "1.0.1"
"version": "1.0.1",
"dev": true
},
"concat-map": {
"version": "0.0.1",
@@ -13679,7 +13849,8 @@
"dev": true
},
"estree-walker": {
"version": "2.0.2"
"version": "2.0.2",
"dev": true
},
"esutils": {
"version": "2.0.3",
@@ -13790,6 +13961,7 @@
},
"find-cache-dir": {
"version": "3.3.2",
"dev": true,
"requires": {
"commondir": "^1.0.1",
"make-dir": "^3.0.2",
@@ -13798,6 +13970,7 @@
},
"find-up": {
"version": "4.1.0",
"dev": true,
"requires": {
"locate-path": "^5.0.0",
"path-exists": "^4.0.0"
@@ -13842,6 +14015,7 @@
},
"fs-extra": {
"version": "10.1.0",
"dev": true,
"requires": {
"graceful-fs": "^4.2.0",
"jsonfile": "^6.0.1",
@@ -13860,7 +14034,8 @@
"dev": true
},
"function-bind": {
"version": "1.1.1"
"version": "1.1.1",
"dev": true
},
"function.prototype.name": {
"version": "1.1.5",
@@ -13964,7 +14139,8 @@
}
},
"graceful-fs": {
"version": "4.2.10"
"version": "4.2.10",
"dev": true
},
"gzip-size": {
"version": "7.0.0",
@@ -13981,6 +14157,7 @@
},
"has": {
"version": "1.0.3",
"dev": true,
"requires": {
"function-bind": "^1.1.1"
}
@@ -14164,6 +14341,7 @@
},
"is-core-module": {
"version": "2.9.0",
"dev": true,
"requires": {
"has": "^1.0.3"
}
@@ -15073,6 +15251,7 @@
},
"jsonfile": {
"version": "6.1.0",
"dev": true,
"requires": {
"graceful-fs": "^4.1.6",
"universalify": "^2.0.0"
@@ -15137,6 +15316,7 @@
},
"locate-path": {
"version": "5.0.0",
"dev": true,
"requires": {
"p-locate": "^4.1.0"
}
@@ -15192,6 +15372,7 @@
},
"make-dir": {
"version": "3.1.0",
"dev": true,
"requires": {
"semver": "^6.0.0"
}
@@ -15276,6 +15457,12 @@
"version": "1.0.4",
"dev": true
},
"moment": {
"version": "2.29.4",
"resolved": "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz",
"integrity": "sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==",
"dev": true
},
"ms": {
"version": "2.1.2",
"dev": true
@@ -15575,12 +15762,14 @@
},
"p-limit": {
"version": "2.3.0",
"dev": true,
"requires": {
"p-try": "^2.0.0"
}
},
"p-locate": {
"version": "4.1.0",
"dev": true,
"requires": {
"p-limit": "^2.2.0"
}
@@ -15608,7 +15797,8 @@
}
},
"p-try": {
"version": "2.2.0"
"version": "2.2.0",
"dev": true
},
"package-hash": {
"version": "4.0.0",
@@ -15620,6 +15810,12 @@
"release-zalgo": "^1.0.0"
}
},
"package-name-regex": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/package-name-regex/-/package-name-regex-2.0.6.tgz",
"integrity": "sha512-gFL35q7kbE/zBaPA3UKhp2vSzcPYx2ecbYuwv1ucE9Il6IIgBDweBlH8D68UFGZic2MkllKa2KHCfC1IQBQUYA==",
"dev": true
},
"parent-module": {
"version": "1.0.1",
"dev": true,
@@ -15642,7 +15838,8 @@
"dev": true
},
"path-exists": {
"version": "4.0.0"
"version": "4.0.0",
"dev": true
},
"path-is-absolute": {
"version": "1.0.1",
@@ -15653,7 +15850,8 @@
"dev": true
},
"path-parse": {
"version": "1.0.7"
"version": "1.0.7",
"dev": true
},
"path-type": {
"version": "4.0.0",
@@ -15664,7 +15862,8 @@
"dev": true
},
"picomatch": {
"version": "2.3.1"
"version": "2.3.1",
"dev": true
},
"pirates": {
"version": "4.0.5",
@@ -15672,6 +15871,7 @@
},
"pkg-dir": {
"version": "4.2.0",
"dev": true,
"requires": {
"find-up": "^4.0.0"
}
@@ -16159,6 +16359,7 @@
},
"resolve": {
"version": "1.22.1",
"dev": true,
"requires": {
"is-core-module": "^2.9.0",
"path-parse": "^1.0.7",
@@ -16193,6 +16394,7 @@
},
"rollup": {
"version": "2.75.7",
"dev": true,
"requires": {
"fsevents": "~2.3.2"
}
@@ -16244,6 +16446,34 @@
"dev": true,
"requires": {}
},
"rollup-plugin-license": {
"version": "2.8.1",
"resolved": "https://registry.npmjs.org/rollup-plugin-license/-/rollup-plugin-license-2.8.1.tgz",
"integrity": "sha512-VYd9pzaNL7NN6xQp93XiiCV2UoduXgSmTcz6rl9bHPdiifT6yH3Zw/omEr73Rq8TIyN4nqJACBbKIT/2eE66wg==",
"dev": true,
"requires": {
"commenting": "~1.1.0",
"glob": "~7.2.0",
"lodash": "~4.17.21",
"magic-string": "~0.26.2",
"mkdirp": "~1.0.4",
"moment": "~2.29.3",
"package-name-regex": "~2.0.6",
"spdx-expression-validate": "~2.0.0",
"spdx-satisfies": "~5.0.1"
},
"dependencies": {
"magic-string": {
"version": "0.26.2",
"resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.26.2.tgz",
"integrity": "sha512-NzzlXpclt5zAbmo6h6jNc8zl2gNRGHvmsZW4IvZhTC4W7k4OlLP+S5YLussa/r3ixNT66KOQfNORlXHSOy/X4A==",
"dev": true,
"requires": {
"sourcemap-codec": "^1.4.8"
}
}
}
},
"rollup-plugin-livereload": {
"version": "2.0.5",
"dev": true,
@@ -16336,6 +16566,7 @@
"version": "0.32.1",
"resolved": "https://registry.npmjs.org/rollup-plugin-typescript2/-/rollup-plugin-typescript2-0.32.1.tgz",
"integrity": "sha512-RanO8bp1WbeMv0bVlgcbsFNCn+Y3rX7wF97SQLDxf0fMLsg0B/QFF005t4AsGUcDgF3aKJHoqt4JF2xVaABeKw==",
"dev": true,
"requires": {
"@rollup/pluginutils": "^4.1.2",
"find-cache-dir": "^3.3.2",
@@ -16348,6 +16579,7 @@
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-4.2.1.tgz",
"integrity": "sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ==",
"dev": true,
"requires": {
"estree-walker": "^2.0.1",
"picomatch": "^2.2.2"
@@ -16402,7 +16634,8 @@
}
},
"semver": {
"version": "6.3.0"
"version": "6.3.0",
"dev": true
},
"serialize-javascript": {
"version": "4.0.0",
@@ -16534,6 +16767,65 @@
"which": "^2.0.1"
}
},
"spdx-compare": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/spdx-compare/-/spdx-compare-1.0.0.tgz",
"integrity": "sha512-C1mDZOX0hnu0ep9dfmuoi03+eOdDoz2yvK79RxbcrVEG1NO1Ph35yW102DHWKN4pk80nwCgeMmSY5L25VE4D9A==",
"dev": true,
"requires": {
"array-find-index": "^1.0.2",
"spdx-expression-parse": "^3.0.0",
"spdx-ranges": "^2.0.0"
}
},
"spdx-exceptions": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz",
"integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==",
"dev": true
},
"spdx-expression-parse": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz",
"integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==",
"dev": true,
"requires": {
"spdx-exceptions": "^2.1.0",
"spdx-license-ids": "^3.0.0"
}
},
"spdx-expression-validate": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/spdx-expression-validate/-/spdx-expression-validate-2.0.0.tgz",
"integrity": "sha512-b3wydZLM+Tc6CFvaRDBOF9d76oGIHNCLYFeHbftFXUWjnfZWganmDmvtM5sm1cRwJc/VDBMLyGGrsLFd1vOxbg==",
"dev": true,
"requires": {
"spdx-expression-parse": "^3.0.0"
}
},
"spdx-license-ids": {
"version": "3.0.11",
"resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.11.tgz",
"integrity": "sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==",
"dev": true
},
"spdx-ranges": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/spdx-ranges/-/spdx-ranges-2.1.1.tgz",
"integrity": "sha512-mcdpQFV7UDAgLpXEE/jOMqvK4LBoO0uTQg0uvXUewmEFhpiZx5yJSZITHB8w1ZahKdhfZqP5GPEOKLyEq5p8XA==",
"dev": true
},
"spdx-satisfies": {
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/spdx-satisfies/-/spdx-satisfies-5.0.1.tgz",
"integrity": "sha512-Nwor6W6gzFp8XX4neaKQ7ChV4wmpSh2sSDemMFSzHxpTw460jxFYeOn+jq4ybnSSw/5sc3pjka9MQPouksQNpw==",
"dev": true,
"requires": {
"spdx-compare": "^1.0.0",
"spdx-expression-parse": "^3.0.0",
"spdx-ranges": "^2.0.0"
}
},
"split-on-first": {
"version": "1.1.0",
"dev": true
@@ -16674,7 +16966,8 @@
}
},
"supports-preserve-symlinks-flag": {
"version": "1.0.0"
"version": "1.0.0",
"dev": true
},
"svgo": {
"version": "2.8.0",
@@ -16803,7 +17096,8 @@
}
},
"tslib": {
"version": "2.4.0"
"version": "2.4.0",
"dev": true
},
"tsutils": {
"version": "3.21.0",
@@ -16841,7 +17135,8 @@
}
},
"typescript": {
"version": "4.7.4"
"version": "4.7.4",
"dev": true
},
"unbox-primitive": {
"version": "1.0.2",
@@ -16874,7 +17169,8 @@
"dev": true
},
"universalify": {
"version": "2.0.0"
"version": "2.0.0",
"dev": true
},
"update-browserslist-db": {
"version": "1.0.3",
+3 -4
View File
@@ -49,7 +49,6 @@
"glob": "^7.1.6",
"jest": "^28.1.3",
"jest-environment-jsdom": "^28.1.3",
"sass": "^1.54.0",
"nyc": "^15.1.0",
"playwright": "^1.22.2",
"playwright-chromium": "^1.22.2",
@@ -62,12 +61,15 @@
"rollup-plugin-dts": "^4.2.2",
"rollup-plugin-esbuild": "^4.9.1",
"rollup-plugin-ignore-import": "^1.3.2",
"rollup-plugin-license": "^2.8.1",
"rollup-plugin-livereload": "^2.0.0",
"rollup-plugin-scss": "^3.0.0",
"rollup-plugin-serve": "^1.1.0",
"rollup-plugin-styles": "^4.0.0",
"rollup-plugin-summary": "^1.4.3",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.32.1",
"sass": "^1.54.0",
"should": "^13.2.3",
"tslib": "^2.4.0",
"typescript": "^4.7.4",
@@ -80,8 +82,5 @@
"playwright:dev": "npm run test:playwright:dev --workspace=overlayscrollbars",
"build": "npm run build --workspace=overlayscrollbars",
"lint": "npx eslint --fix ."
},
"dependencies": {
"rollup-plugin-typescript2": "^0.32.1"
}
}
@@ -1,3 +1,13 @@
/*!
* OverlayScrollbars
* Version: 2.0.0-beta.0
*
* Copyright (c) Rene Haas | KingSora.
* https://github.com/KingSora
*
* Released under the MIT license.
*/
function each(t, n) {
if (isArrayLike(t)) {
for (let o = 0; o < t.length; o++) {
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+10
View File
@@ -1,3 +1,13 @@
/*!
* OverlayScrollbars
* Version: 2.0.0-beta.0
*
* Copyright (c) Rene Haas | KingSora.
* https://github.com/KingSora
*
* Released under the MIT license.
*/
(function(r, a) {
"object" === typeof exports && "undefined" !== typeof module ? a(exports) : "function" === typeof define && define.amd ? define([ "exports" ], a) : (r = "undefined" !== typeof globalThis ? globalThis : r || self,
a(r.OverlayScrollbars = {}));
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+8 -1
View File
@@ -1,13 +1,20 @@
const { terser: rollupTerser } = require('rollup-plugin-terser');
const { summary } = require('rollup-plugin-summary');
const createRollupConfig = require('@local/rollup');
const { devDependencies, peerDependencies } = require('./package.json');
const { devDependencies, peerDependencies, version } = require('./package.json');
module.exports = createRollupConfig({
project: 'OverlayScrollbars',
verbose: true,
extractStyles: true,
extractTypes: true,
banner: `OverlayScrollbars
Version: ${version}
Copyright (c) Rene Haas | KingSora.
https://github.com/KingSora
Released under the MIT license.`,
rollup: {
external: Object.keys(devDependencies || {}).concat(Object.keys(peerDependencies || {})),
output: {