@jsenv/core 39.2.9 → 39.2.11

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.
@@ -1286,6 +1286,9 @@ const createTaskLog = (
1286
1286
  fail: () => {},
1287
1287
  };
1288
1288
  }
1289
+ if (animated && process.env.SNAPSHOTING_FUNCTION_SIDE_EFFECTS) {
1290
+ animated = false;
1291
+ }
1289
1292
  const startMs = Date.now();
1290
1293
  const dynamicLog = createDynamicLog();
1291
1294
  let message = label;
@@ -1680,7 +1683,11 @@ const getCommonPathname = (pathname, otherPathname) => {
1680
1683
  return commonPathname;
1681
1684
  };
1682
1685
 
1683
- const urlToRelativeUrl = (url, baseUrl) => {
1686
+ const urlToRelativeUrl = (
1687
+ url,
1688
+ baseUrl,
1689
+ { preferRelativeNotation } = {},
1690
+ ) => {
1684
1691
  const urlObject = new URL(url);
1685
1692
  const baseUrlObject = new URL(baseUrl);
1686
1693
 
@@ -1724,7 +1731,7 @@ const urlToRelativeUrl = (url, baseUrl) => {
1724
1731
  }
1725
1732
 
1726
1733
  const relativeUrl = `${specificPathname}${search}${hash}`;
1727
- return relativeUrl;
1734
+ return preferRelativeNotation ? `./${relativeUrl}` : relativeUrl;
1728
1735
  };
1729
1736
 
1730
1737
  const pathnameToParentPathname$1 = (pathname) => {
@@ -3048,6 +3055,19 @@ const isWindowsPathnameSpecifier = (specifier) => {
3048
3055
  };
3049
3056
  const hasScheme$1 = (specifier) => /^[a-zA-Z]+:/.test(specifier);
3050
3057
 
3058
+ const createFilter = (patterns, url) => {
3059
+ const associations = resolveAssociations(
3060
+ {
3061
+ yes: patterns,
3062
+ },
3063
+ url,
3064
+ );
3065
+ return (url) => {
3066
+ const meta = applyAssociations({ url, associations });
3067
+ return Boolean(meta.yes);
3068
+ };
3069
+ };
3070
+
3051
3071
  const URL_META = {
3052
3072
  resolveAssociations,
3053
3073
  applyAssociations,
@@ -3055,6 +3075,7 @@ const URL_META = {
3055
3075
  applyPatternMatching,
3056
3076
  urlChildMayMatch,
3057
3077
  matches,
3078
+ createFilter,
3058
3079
  };
3059
3080
 
3060
3081
  const readDirectory = async (url, { emfileMaxWait = 1000 } = {}) => {
@@ -21759,8 +21780,6 @@ const defaultRuntimeCompat = {
21759
21780
  * @param {('none'|'inline'|'file'|'programmatic'} [buildParameters.sourcemaps="none"]
21760
21781
  * Generate sourcemaps in the build directory
21761
21782
  * @return {Object} buildReturnValue
21762
- * @return {Object} buildReturnValue.buildFileContents
21763
- * Contains all build file paths relative to the build directory and their content
21764
21783
  * @return {Object} buildReturnValue.buildInlineContents
21765
21784
  * Contains content that is inline into build files
21766
21785
  * @return {Object} buildReturnValue.buildManifest
@@ -22330,7 +22349,6 @@ build ${entryPointKeys.length} entry points`);
22330
22349
  }),
22331
22350
  );
22332
22351
  return {
22333
- buildFileContents,
22334
22352
  buildInlineContents,
22335
22353
  buildManifest,
22336
22354
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/core",
3
- "version": "39.2.9",
3
+ "version": "39.2.11",
4
4
  "description": "Tool to develop, test and build js projects",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -66,22 +66,22 @@
66
66
  "dependencies": {
67
67
  "@financial-times/polyfill-useragent-normaliser": "1.10.2",
68
68
  "@jsenv/abort": "4.3.0",
69
- "@jsenv/ast": "6.2.7",
70
- "@jsenv/filesystem": "4.9.4",
71
- "@jsenv/humanize": "1.2.5",
69
+ "@jsenv/ast": "6.2.9",
70
+ "@jsenv/filesystem": "4.9.5",
71
+ "@jsenv/humanize": "1.2.6",
72
72
  "@jsenv/importmap": "1.2.1",
73
73
  "@jsenv/integrity": "0.0.2",
74
- "@jsenv/js-module-fallback": "1.3.28",
74
+ "@jsenv/js-module-fallback": "1.3.30",
75
75
  "@jsenv/node-esm-resolution": "1.0.2",
76
- "@jsenv/plugin-bundling": "2.7.1",
76
+ "@jsenv/plugin-bundling": "2.7.2",
77
77
  "@jsenv/plugin-minification": "1.5.5",
78
- "@jsenv/plugin-supervisor": "1.5.8",
79
- "@jsenv/plugin-transpilation": "1.4.12",
78
+ "@jsenv/plugin-supervisor": "1.5.10",
79
+ "@jsenv/plugin-transpilation": "1.4.14",
80
80
  "@jsenv/runtime-compat": "1.3.1",
81
- "@jsenv/server": "15.2.15",
82
- "@jsenv/sourcemap": "1.2.18",
83
- "@jsenv/url-meta": "8.4.2",
84
- "@jsenv/urls": "2.4.0",
81
+ "@jsenv/server": "15.2.16",
82
+ "@jsenv/sourcemap": "1.2.19",
83
+ "@jsenv/url-meta": "8.5.0",
84
+ "@jsenv/urls": "2.4.1",
85
85
  "@jsenv/utils": "2.1.2"
86
86
  },
87
87
  "devDependencies": {
@@ -81,8 +81,6 @@ export const defaultRuntimeCompat = {
81
81
  * @param {('none'|'inline'|'file'|'programmatic'} [buildParameters.sourcemaps="none"]
82
82
  * Generate sourcemaps in the build directory
83
83
  * @return {Object} buildReturnValue
84
- * @return {Object} buildReturnValue.buildFileContents
85
- * Contains all build file paths relative to the build directory and their content
86
84
  * @return {Object} buildReturnValue.buildInlineContents
87
85
  * Contains content that is inline into build files
88
86
  * @return {Object} buildReturnValue.buildManifest
@@ -654,7 +652,6 @@ build ${entryPointKeys.length} entry points`);
654
652
  }),
655
653
  );
656
654
  return {
657
- buildFileContents,
658
655
  buildInlineContents,
659
656
  buildManifest,
660
657
  };