@genesislcap/ts-builder 14.418.2 → 14.419.1

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/ts-builder",
3
3
  "description": "Typescript builder",
4
- "version": "14.418.2",
4
+ "version": "14.419.1",
5
5
  "license": "SEE LICENSE IN license.txt",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -17,7 +17,7 @@
17
17
  },
18
18
  "dependencies": {
19
19
  "@custom-elements-manifest/analyzer": "^0.8.2",
20
- "@genesislcap/build-kit": "14.418.2",
20
+ "@genesislcap/build-kit": "14.419.1",
21
21
  "consola": "^3.0.2",
22
22
  "copyfiles": "^2.4.1",
23
23
  "pkg-types": "^1.0.2"
@@ -30,5 +30,5 @@
30
30
  "publishConfig": {
31
31
  "access": "public"
32
32
  },
33
- "gitHead": "ae9a9252a0ca0d35759886db9b502921e3a3e831"
33
+ "gitHead": "e4880f9a62bd7ebb0a0e4798c8dfdd98de5c6e14"
34
34
  }
package/src/index.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { rm, run, resolveBin } from '@genesislcap/build-kit';
2
2
  import type { BuildContext } from '@genesislcap/build-kit';
3
3
  import consola from 'consola';
4
+ import { generateReactWrappers } from './react-wrapper-generator';
4
5
 
5
6
  export default async (ctx: BuildContext) => {
6
7
  const {
@@ -42,6 +43,15 @@ export default async (ctx: BuildContext) => {
42
43
  const cem = await resolveBin('cem', '@custom-elements-manifest/analyzer');
43
44
  run(cwd, `${cem} analyze --config custom-elements-manifest.config.*js`);
44
45
  }
46
+
47
+ const reactWrappersResult = await generateReactWrappers(cwd);
48
+ if (reactWrappersResult.generated) {
49
+ consola.log(`\nReact wrappers generated: ${reactWrappersResult.path}`);
50
+ } else {
51
+ // strictNullChecks is off in this workspace, so boolean literal narrowing
52
+ // doesn't apply to the discriminated union — cast to access the skipped variant.
53
+ consola.debug(`React wrappers skipped: ${(reactWrappersResult as { reason: string }).reason}`);
54
+ }
45
55
  } else {
46
56
  throw new Error(`Unrecognized command: ${JSON.stringify(options)}`);
47
57
  }