@lwrjs/tools 0.10.0-alpha.19 → 0.10.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.
@@ -61,11 +61,11 @@ function processHooks(hooksConfig, hooks, rootDir) {
61
61
  entries: []
62
62
  };
63
63
  for (const [index, [entry, config]] of hooksConfig.entries()) {
64
- if (!hooks[index].onStart) {
64
+ if (!hooks[index].onStart && !hooks[index].initInstrumentation) {
65
65
  continue;
66
66
  }
67
67
  if (hooks[index].initConfigs) {
68
- import_shared_utils.logger.warn("Consider splitting `initConfigs` hooks to a file separate from `onStart`.");
68
+ import_shared_utils.logger.warn("Consider splitting `initConfigs` hooks to a separate file.");
69
69
  }
70
70
  const name = "hook" + index;
71
71
  output.imports.push(`import ${name} from '${(0, import_shared_utils.normalizeDirectory)(entry, rootDir)}';`);
@@ -79,7 +79,8 @@ function createEnvVarHeader() {
79
79
  initFeatureFlagsString += `process.env.${key} = 'true';`;
80
80
  }
81
81
  }
82
+ const LWR_TRACING = `process.env.LWR_TRACING = 'default';`;
82
83
  const LWR_VERSION_ASSIGNMENT = `globalThis.LWR_VERSION='${import_config.LWR_VERSION}';`;
83
84
  const LWC_VERSION_ASSIGNMENT = `globalThis.LWC_VERSION='${import_config.LWC_VERSION}';`;
84
- return `${LWR_VERSION_ASSIGNMENT}${LWC_VERSION_ASSIGNMENT}${initFeatureFlagsString}`;
85
+ return `${LWR_VERSION_ASSIGNMENT}${LWC_VERSION_ASSIGNMENT}${initFeatureFlagsString}${LWR_TRACING}`;
85
86
  }
@@ -33,11 +33,11 @@ function processHooks(hooksConfig, hooks, rootDir) {
33
33
  entries: [],
34
34
  };
35
35
  for (const [index, [entry, config]] of hooksConfig.entries()) {
36
- if (!hooks[index].onStart) {
36
+ if (!hooks[index].onStart && !hooks[index].initInstrumentation) {
37
37
  continue;
38
38
  }
39
39
  if (hooks[index].initConfigs) {
40
- logger.warn('Consider splitting `initConfigs` hooks to a file separate from `onStart`.');
40
+ logger.warn('Consider splitting `initConfigs` hooks to a separate file.');
41
41
  }
42
42
  const name = 'hook' + index;
43
43
  output.imports.push(`import ${name} from '${normalizeDirectory(entry, rootDir)}';`);
@@ -71,8 +71,9 @@ function createEnvVarHeader() {
71
71
  initFeatureFlagsString += `process.env.${key} = 'true';`;
72
72
  }
73
73
  }
74
+ const LWR_TRACING = `process.env.LWR_TRACING = 'default';`;
74
75
  const LWR_VERSION_ASSIGNMENT = `globalThis.LWR_VERSION='${LWR_VERSION}';`;
75
76
  const LWC_VERSION_ASSIGNMENT = `globalThis.LWC_VERSION='${LWC_VERSION}';`;
76
- return `${LWR_VERSION_ASSIGNMENT}${LWC_VERSION_ASSIGNMENT}${initFeatureFlagsString}`;
77
+ return `${LWR_VERSION_ASSIGNMENT}${LWC_VERSION_ASSIGNMENT}${initFeatureFlagsString}${LWR_TRACING}`;
77
78
  }
78
79
  //# sourceMappingURL=server-build.js.map
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.10.0-alpha.19",
7
+ "version": "0.10.0-alpha.20",
8
8
  "homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
9
9
  "repository": {
10
10
  "type": "git",
@@ -32,11 +32,11 @@
32
32
  "package.cjs"
33
33
  ],
34
34
  "dependencies": {
35
- "@lwrjs/core": "0.10.0-alpha.19",
35
+ "@lwrjs/core": "0.10.0-alpha.20",
36
36
  "esbuild": "^0.17.4"
37
37
  },
38
38
  "devDependencies": {
39
- "@lwrjs/types": "0.10.0-alpha.19"
39
+ "@lwrjs/types": "0.10.0-alpha.20"
40
40
  },
41
41
  "peerDependencies": {
42
42
  "lwc": "2.x"
@@ -44,5 +44,5 @@
44
44
  "engines": {
45
45
  "node": ">=16.0.0"
46
46
  },
47
- "gitHead": "0bd55139c08ddf5a532978cfa9e037eaf27e78e2"
47
+ "gitHead": "45a867fc54e98f77dd442ccd5f668e23027b9246"
48
48
  }