@lwrjs/module-bundler 0.13.0-alpha.19 → 0.13.0-alpha.20

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.
@@ -29,11 +29,6 @@ __export(exports, {
29
29
  });
30
30
  var import_diagnostics = __toModule(require("@lwrjs/diagnostics"));
31
31
  var import_esbuild = __toModule(require("esbuild"));
32
- var import_features = __toModule(require("@lwc/features"));
33
- var lwcFeatureFlags = "default" in import_features.default ? import_features.default.default : import_features.default;
34
- var lwcFeatureFlagDefinitions = Object.fromEntries(Object.keys(lwcFeatureFlags).map((feature) => [`lwcRuntimeFlags.${feature}`, "false"]));
35
- delete lwcFeatureFlagDefinitions["lwcRuntimeFlags.ENABLE_MIXED_SHADOW_MODE"];
36
- delete lwcFeatureFlagDefinitions["lwcRuntimeFlags.DISABLE_NATIVE_CUSTOM_ELEMENT_LIFECYCLE"];
37
32
  var esbuild = import_esbuild.default;
38
33
  if (!import_esbuild.default) {
39
34
  try {
@@ -47,8 +42,7 @@ async function minifyJavascript(source) {
47
42
  loader: "js",
48
43
  minify: true,
49
44
  define: {
50
- "process.env.NODE_ENV": JSON.stringify("production"),
51
- ...lwcFeatureFlagDefinitions
45
+ "process.env.NODE_ENV": JSON.stringify("production")
52
46
  }
53
47
  });
54
48
  return code;
@@ -65,8 +59,7 @@ async function parseJavascript(source, options) {
65
59
  loader: "js",
66
60
  minify: false,
67
61
  define: {
68
- "process.env.NODE_ENV": JSON.stringify(options.envMode),
69
- ...lwcFeatureFlagDefinitions
62
+ "process.env.NODE_ENV": JSON.stringify(options.envMode)
70
63
  }
71
64
  });
72
65
  return code;
@@ -1,14 +1,5 @@
1
1
  import { logger } from '@lwrjs/diagnostics';
2
2
  import esbuildEsm from 'esbuild';
3
- import features from '@lwc/features';
4
- // In certain envs, this default import is not compiled correctly
5
- const lwcFeatureFlags = 'default' in features ? features.default : features;
6
- // Set every LWC feature flag to false, so that the unused code can be tree-shaken
7
- const lwcFeatureFlagDefinitions = Object.fromEntries(Object.keys(lwcFeatureFlags).map((feature) => [`lwcRuntimeFlags.${feature}`, 'false']));
8
- // We cannot set mixed mode to false across the app; it varies by route.
9
- delete lwcFeatureFlagDefinitions['lwcRuntimeFlags.ENABLE_MIXED_SHADOW_MODE'];
10
- // We need to toggle this in production to test native vs synthetic lifecycle
11
- delete lwcFeatureFlagDefinitions['lwcRuntimeFlags.DISABLE_NATIVE_CUSTOM_ELEMENT_LIFECYCLE'];
12
3
  // https://github.com/evanw/esbuild/issues/706
13
4
  // Fixed in 0.11.0 but upgrading past 0.9.7 has caused breaking changes for consumers...
14
5
  // https://github.com/salesforce-experience-platform-emu/lwr/issues/1014
@@ -33,7 +24,6 @@ export async function minifyJavascript(source) {
33
24
  // Remove assertions by tree shaking the computed expression
34
25
  define: {
35
26
  'process.env.NODE_ENV': JSON.stringify('production'),
36
- ...lwcFeatureFlagDefinitions,
37
27
  },
38
28
  });
39
29
  return code;
@@ -57,7 +47,6 @@ export async function parseJavascript(source, options) {
57
47
  // Remove assertions by tree shaking the computed expression
58
48
  define: {
59
49
  'process.env.NODE_ENV': JSON.stringify(options.envMode),
60
- ...lwcFeatureFlagDefinitions,
61
50
  },
62
51
  });
63
52
  return code;
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.13.0-alpha.19",
7
+ "version": "0.13.0-alpha.20",
8
8
  "homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
9
9
  "repository": {
10
10
  "type": "git",
@@ -47,28 +47,25 @@
47
47
  "build/**/*.d.ts"
48
48
  ],
49
49
  "dependencies": {
50
- "@lwrjs/diagnostics": "0.13.0-alpha.19",
51
- "@lwrjs/instrumentation": "0.13.0-alpha.19",
52
- "@lwrjs/shared-utils": "0.13.0-alpha.19",
53
- "@rollup/plugin-replace": "^5.0.5",
50
+ "@lwrjs/diagnostics": "0.13.0-alpha.20",
51
+ "@lwrjs/instrumentation": "0.13.0-alpha.20",
52
+ "@lwrjs/shared-utils": "0.13.0-alpha.20",
53
+ "@rollup/plugin-replace": "^5.0.7",
54
54
  "rollup": "^2.78.0"
55
55
  },
56
56
  "devDependencies": {
57
- "@lwrjs/types": "0.13.0-alpha.19",
57
+ "@lwrjs/types": "0.13.0-alpha.20",
58
58
  "jest": "^26.6.3",
59
59
  "ts-jest": "^26.5.6"
60
60
  },
61
61
  "optionalDependencies": {
62
62
  "esbuild": "^0.9.7"
63
63
  },
64
- "peerDependencies": {
65
- "@lwc/features": ">= 2.x"
66
- },
67
64
  "engines": {
68
65
  "node": ">=18.0.0"
69
66
  },
70
67
  "volta": {
71
68
  "extends": "../../../package.json"
72
69
  },
73
- "gitHead": "759feb96937059dc3b209c1ac9425d053d46db9a"
70
+ "gitHead": "2165594f2871f4f20a4083394e4372e67d1fa1b5"
74
71
  }