@ms-cloudpack/bundler 0.23.28 → 0.23.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -15,7 +15,7 @@ const resourceExtensions = [
|
|
|
15
15
|
'.woff',
|
|
16
16
|
'.woff2',
|
|
17
17
|
];
|
|
18
|
-
const nonJsSourceExtensions = ['.json', '.css', '.scss'];
|
|
18
|
+
const nonJsSourceExtensions = ['.json', '.css', '.scss', '.wasm'];
|
|
19
19
|
const textExtensions = ['.htm', '.html', '.txt'];
|
|
20
20
|
const supportedExtensions = [...resourceExtensions, ...sourceExtensions, ...nonJsSourceExtensions, ...textExtensions];
|
|
21
21
|
// Note: excluded extensions only need to contain things that are allowed by supportedExtensions but using
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isValidBundleEntry.js","sourceRoot":"","sources":["../src/isValidBundleEntry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,MAAM,kBAAkB,GAAG;IACzB,MAAM;IACN,MAAM;IACN,OAAO;IACP,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,OAAO;IACP,OAAO;IACP,QAAQ;CACT,CAAC;AACF,MAAM,qBAAqB,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"isValidBundleEntry.js","sourceRoot":"","sources":["../src/isValidBundleEntry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,MAAM,kBAAkB,GAAG;IACzB,MAAM;IACN,MAAM;IACN,OAAO;IACP,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,MAAM;IACN,OAAO;IACP,OAAO;IACP,QAAQ;CACT,CAAC;AACF,MAAM,qBAAqB,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AAClE,MAAM,cAAc,GAAG,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;AACjD,MAAM,mBAAmB,GAAG,CAAC,GAAG,kBAAkB,EAAE,GAAG,gBAAgB,EAAE,GAAG,qBAAqB,EAAE,GAAG,cAAc,CAAC,CAAC;AAEtH,0GAA0G;AAC1G,6GAA6G;AAC7G,MAAM,kBAAkB,GAAG,CAAC,OAAO,CAAC,CAAC;AAErC;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAAC,QAAgB;IACjD,MAAM,WAAW,GAAG,mBAAmB,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC;IACvF,MAAM,UAAU,GACd,kBAAkB,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;QACxE,wGAAwG;QACxG,gEAAgE;QAChE,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,WAAW,EAAE,KAAK,OAAO,CAAC,CAAC;IAEhG,OAAO,WAAW,IAAI,CAAC,UAAU,CAAC;AACpC,CAAC","sourcesContent":["import { sourceExtensions } from '@ms-cloudpack/path-utilities';\nimport path from 'path';\n\nconst resourceExtensions = [\n '.bmp',\n '.gif',\n '.jpeg',\n '.jpg',\n '.mp3',\n '.mp4',\n '.otf',\n '.png',\n '.svg',\n '.ttf',\n '.webp',\n '.woff',\n '.woff2',\n];\nconst nonJsSourceExtensions = ['.json', '.css', '.scss', '.wasm'];\nconst textExtensions = ['.htm', '.html', '.txt'];\nconst supportedExtensions = [...resourceExtensions, ...sourceExtensions, ...nonJsSourceExtensions, ...textExtensions];\n\n// Note: excluded extensions only need to contain things that are allowed by supportedExtensions but using\n// an extended syntax that we don't want to support. For example, we want to support .ts files but not .d.ts.\nconst excludedExtensions = ['.d.ts'];\n\n/**\n * Returns true if the file path is a valid bundle-able file extension. This is used to filter exports maps out\n * to ensure we prevent trying to bundle things that bundlers don't support. We can bundle things like TS,\n * JS, CSS, SCSS, JSON, and even text extensions like .txt and .html. These formats all will produce javascript\n * modules. \"Valid\" is defined by what the bundler abstraction expects. In the future we may want this code to be\n * provided by the plugin itself so that it owns what's \"supported\".\n */\nexport function isValidBundleEntry(filePath: string): boolean {\n const isSupported = supportedExtensions.includes(path.extname(filePath).toLowerCase());\n const isExcluded =\n excludedExtensions.some((excludedExt) => filePath.endsWith(excludedExt)) ||\n // Exclude files that start with an underscore, as they are typically partials or other non-entry files.\n // https://sass-lang.com/documentation/at-rules/import/#partials\n (path.basename(filePath).startsWith('_') && path.extname(filePath).toLowerCase() === '.scss');\n\n return isSupported && !isExcluded;\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ms-cloudpack/bundler",
|
|
3
|
-
"version": "0.23.
|
|
3
|
+
"version": "0.23.30",
|
|
4
4
|
"description": "An abstraction to bundle source code.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -14,16 +14,16 @@
|
|
|
14
14
|
}
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@ms-cloudpack/bundler-ori": "^0.2.
|
|
18
|
-
"@ms-cloudpack/bundler-rollup": "^0.2.
|
|
19
|
-
"@ms-cloudpack/bundler-rspack": "^0.2.
|
|
20
|
-
"@ms-cloudpack/bundler-webpack": "^0.2.
|
|
21
|
-
"@ms-cloudpack/common-types": "^0.24.
|
|
22
|
-
"@ms-cloudpack/config": "^0.33.
|
|
17
|
+
"@ms-cloudpack/bundler-ori": "^0.2.13",
|
|
18
|
+
"@ms-cloudpack/bundler-rollup": "^0.2.7",
|
|
19
|
+
"@ms-cloudpack/bundler-rspack": "^0.2.17",
|
|
20
|
+
"@ms-cloudpack/bundler-webpack": "^0.2.15",
|
|
21
|
+
"@ms-cloudpack/common-types": "^0.24.1",
|
|
22
|
+
"@ms-cloudpack/config": "^0.33.7",
|
|
23
23
|
"@ms-cloudpack/json-utilities": "^0.1.10",
|
|
24
|
-
"@ms-cloudpack/package-utilities": "^11.1.
|
|
24
|
+
"@ms-cloudpack/package-utilities": "^11.1.1",
|
|
25
25
|
"@ms-cloudpack/path-string-parsing": "^1.2.6",
|
|
26
|
-
"@ms-cloudpack/path-utilities": "^2.8.
|
|
26
|
+
"@ms-cloudpack/path-utilities": "^2.8.2"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@ms-cloudpack/eslint-plugin-internal": "^0.0.1",
|