@powerlines/plugin-react 0.1.47 → 0.1.49
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/README.md +8 -2
- package/dist/chunk-CF6LXmkI.mjs +1 -0
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.d.cts +4 -6
- package/dist/components/index.d.mts +4 -0
- package/dist/components/index.mjs +1 -0
- package/dist/components/react-optimized.cjs +1 -8
- package/dist/components/react-optimized.d.cts +3 -95
- package/dist/components/react-optimized.d.mts +3 -0
- package/dist/components/react-optimized.mjs +1 -0
- package/dist/components-MTvNCZDU.mjs +1 -0
- package/dist/index-B8OHl-c_.d.mts +1 -0
- package/dist/index-BR1oNnaF.d.cts +1 -0
- package/dist/index-CFG0_wK4.d.cts +1 -0
- package/dist/index-DNLi60D-.d.mts +1 -0
- package/dist/index.cjs +67 -8
- package/dist/index.d.cts +32 -53
- package/dist/index.d.cts.map +1 -0
- package/dist/index.d.mts +47 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +65 -0
- package/dist/index.mjs.map +1 -0
- package/dist/plugin-C9ZuWdaR.d.cts +1781 -0
- package/dist/plugin-C9ZuWdaR.d.cts.map +1 -0
- package/dist/plugin-G4qbpIjB.mjs +1 -0
- package/dist/plugin-JgSIR_pC.d.mts +1779 -0
- package/dist/plugin-JgSIR_pC.d.mts.map +1 -0
- package/dist/plugin-sboatcNU.d.mts +1779 -0
- package/dist/plugin-sboatcNU.d.mts.map +1 -0
- package/dist/react-optimized-B4-nlx1E.d.mts +103 -0
- package/dist/react-optimized-B4-nlx1E.d.mts.map +1 -0
- package/dist/react-optimized-BO9knQDM.cjs +1 -0
- package/dist/react-optimized-B_P6YxHv.mjs +2 -0
- package/dist/react-optimized-B_P6YxHv.mjs.map +1 -0
- package/dist/react-optimized-CY318RuO.d.cts +102 -0
- package/dist/react-optimized-CY318RuO.d.cts.map +1 -0
- package/dist/react-optimized-CbXKgStb.d.mts +103 -0
- package/dist/react-optimized-CbXKgStb.d.mts.map +1 -0
- package/dist/resolved-C3sdBJbK.d.mts +1680 -0
- package/dist/resolved-C3sdBJbK.d.mts.map +1 -0
- package/dist/resolved-C8Vvfp78.d.cts +1679 -0
- package/dist/resolved-C8Vvfp78.d.cts.map +1 -0
- package/dist/resolved-cGosdCt1.d.mts +1681 -0
- package/dist/resolved-cGosdCt1.d.mts.map +1 -0
- package/dist/runtime-Bp9G0scd.cjs +0 -0
- package/dist/runtime-CH2w8aTC.d.mts +16 -0
- package/dist/runtime-CH2w8aTC.d.mts.map +1 -0
- package/dist/runtime-DEBqRdSt.d.mts +793 -0
- package/dist/runtime-DEBqRdSt.d.mts.map +1 -0
- package/dist/runtime-DRosxZBg.d.mts +793 -0
- package/dist/runtime-DRosxZBg.d.mts.map +1 -0
- package/dist/runtime-FcS-im6N.d.mts +16 -0
- package/dist/runtime-FcS-im6N.d.mts.map +1 -0
- package/dist/runtime-ag6w6CSq.d.cts +793 -0
- package/dist/runtime-ag6w6CSq.d.cts.map +1 -0
- package/dist/runtime-cDYyRPa0.mjs +1 -0
- package/dist/runtime-e8zq29Og.d.cts +16 -0
- package/dist/runtime-e8zq29Og.d.cts.map +1 -0
- package/dist/types/index.cjs +1 -1
- package/dist/types/index.d.cts +6 -32
- package/dist/types/index.d.mts +6 -0
- package/dist/types/index.mjs +1 -0
- package/dist/types/plugin.cjs +1 -1
- package/dist/types/plugin.d.cts +4 -1796
- package/dist/types/plugin.d.mts +4 -0
- package/dist/types/plugin.mjs +1 -0
- package/dist/types/runtime.cjs +1 -1
- package/dist/types/runtime.d.cts +4 -38
- package/dist/types/runtime.d.mts +4 -0
- package/dist/types/runtime.mjs +1 -0
- package/dist/types-C5ggNT4K.mjs +1 -0
- package/dist/types-a8gm_IaQ.cjs +0 -0
- package/package.json +47 -36
- package/dist/chunk-FBBMZ4NC.cjs +0 -7
- package/dist/chunk-UCUR73HG.js +0 -7
- package/dist/components/index.d.ts +0 -6
- package/dist/components/index.js +0 -1
- package/dist/components/react-optimized.d.ts +0 -95
- package/dist/components/react-optimized.js +0 -8
- package/dist/fs-ECFlqnPg.d.cts +0 -378
- package/dist/fs-ECFlqnPg.d.ts +0 -378
- package/dist/index.d.ts +0 -65
- package/dist/index.js +0 -8
- package/dist/runtime-C5ZrfPiA.d.cts +0 -2008
- package/dist/runtime-kdZZtKC2.d.ts +0 -2008
- package/dist/types/index.d.ts +0 -32
- package/dist/types/index.js +0 -1
- package/dist/types/plugin.d.ts +0 -1796
- package/dist/types/runtime.d.ts +0 -38
- /package/dist/{types/plugin.js → components-BWLXb7a2.cjs} +0 -0
- /package/dist/{types/runtime.js → plugin-pBKbb5K9.cjs} +0 -0
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import "../resolved-C3sdBJbK.mjs";
|
|
2
|
+
import { a as ReactPluginUserConfig, c as __ΩReactPluginOptions, i as ReactPluginResolvedConfig, l as __ΩReactPluginResolvedConfig, n as ReactPluginContext, o as __ΩReactCompilerOptions, r as ReactPluginOptions, s as __ΩReactPluginContext, t as ReactCompilerOptions, u as __ΩReactPluginUserConfig } from "../plugin-sboatcNU.mjs";
|
|
3
|
+
import "../runtime-DRosxZBg.mjs";
|
|
4
|
+
export { ReactCompilerOptions, ReactPluginContext, ReactPluginOptions, ReactPluginResolvedConfig, ReactPluginUserConfig, __ΩReactCompilerOptions, __ΩReactPluginContext, __ΩReactPluginOptions, __ΩReactPluginResolvedConfig, __ΩReactPluginUserConfig };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"../plugin-G4qbpIjB.mjs";export{};
|
package/dist/types/runtime.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
require(`../runtime-Bp9G0scd.cjs`);
|
package/dist/types/runtime.d.cts
CHANGED
|
@@ -1,38 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
import '@stryke/types/package-json';
|
|
6
|
-
import 'jiti';
|
|
7
|
-
import 'magic-string';
|
|
8
|
-
import 'oxc-parser';
|
|
9
|
-
import 'semver';
|
|
10
|
-
import 'ts-morph';
|
|
11
|
-
import 'undici';
|
|
12
|
-
import 'unplugin';
|
|
13
|
-
import '@babel/core';
|
|
14
|
-
import '@storm-software/build-tools/types';
|
|
15
|
-
import '@storm-software/config-tools/types';
|
|
16
|
-
import '@storm-software/config/types';
|
|
17
|
-
import '@stryke/types/configuration';
|
|
18
|
-
import '@stryke/types/file';
|
|
19
|
-
import 'vite';
|
|
20
|
-
import '@babel/helper-plugin-utils';
|
|
21
|
-
import '../fs-ECFlqnPg.cjs';
|
|
22
|
-
import '@stryke/fs/resolve';
|
|
23
|
-
import '@stryke/types/array';
|
|
24
|
-
import '@stryke/types/tsconfig';
|
|
25
|
-
import 'typescript';
|
|
26
|
-
|
|
27
|
-
interface ReactEnvInterface extends EnvInterface {
|
|
28
|
-
/**
|
|
29
|
-
* Disables the React compiler optimizations when set to true.
|
|
30
|
-
*
|
|
31
|
-
* @remarks
|
|
32
|
-
* This environment variable can be used to turn off the optimizations provided by the React compiler, which may be useful for debugging or development purposes.
|
|
33
|
-
*/
|
|
34
|
-
DISABLE_REACT_COMPILER: boolean;
|
|
35
|
-
}
|
|
36
|
-
declare type __ΩReactEnvInterface = any[];
|
|
37
|
-
|
|
38
|
-
export type { ReactEnvInterface, __ΩReactEnvInterface };
|
|
1
|
+
import "../resolved-C8Vvfp78.cjs";
|
|
2
|
+
import "../runtime-ag6w6CSq.cjs";
|
|
3
|
+
import { n as __ΩReactEnvInterface, t as ReactEnvInterface } from "../runtime-e8zq29Og.cjs";
|
|
4
|
+
export { ReactEnvInterface, __ΩReactEnvInterface };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"../runtime-cDYyRPa0.mjs";export{};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{};
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powerlines/plugin-react",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.49",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A package containing a Powerlines plugin for building a React application.",
|
|
6
6
|
"repository": {
|
|
@@ -38,81 +38,93 @@
|
|
|
38
38
|
},
|
|
39
39
|
"license": "Apache-2.0",
|
|
40
40
|
"private": false,
|
|
41
|
-
"typings": "dist/index.d.
|
|
41
|
+
"typings": "dist/index.d.mts",
|
|
42
42
|
"main": "dist/index.cjs",
|
|
43
|
-
"module": "dist/index.
|
|
43
|
+
"module": "dist/index.mjs",
|
|
44
44
|
"exports": {
|
|
45
45
|
"./package.json": "./package.json",
|
|
46
46
|
".": {
|
|
47
|
-
"import": {
|
|
47
|
+
"import": {
|
|
48
|
+
"types": "./dist/index.d.mts",
|
|
49
|
+
"default": "./dist/index.mjs"
|
|
50
|
+
},
|
|
48
51
|
"require": {
|
|
49
52
|
"types": "./dist/index.d.cts",
|
|
50
53
|
"default": "./dist/index.cjs"
|
|
51
54
|
},
|
|
52
|
-
"default": {
|
|
55
|
+
"default": {
|
|
56
|
+
"types": "./dist/index.d.mts",
|
|
57
|
+
"default": "./dist/index.mjs"
|
|
58
|
+
}
|
|
53
59
|
},
|
|
54
60
|
"./index": {
|
|
55
|
-
"import": {
|
|
61
|
+
"import": {
|
|
62
|
+
"types": "./dist/index.d.mts",
|
|
63
|
+
"default": "./dist/index.mjs"
|
|
64
|
+
},
|
|
56
65
|
"require": {
|
|
57
66
|
"types": "./dist/index.d.cts",
|
|
58
67
|
"default": "./dist/index.cjs"
|
|
59
68
|
},
|
|
60
|
-
"default": {
|
|
69
|
+
"default": {
|
|
70
|
+
"types": "./dist/index.d.mts",
|
|
71
|
+
"default": "./dist/index.mjs"
|
|
72
|
+
}
|
|
61
73
|
},
|
|
62
74
|
"./types": {
|
|
63
75
|
"import": {
|
|
64
|
-
"types": "./dist/types/index.d.
|
|
65
|
-
"default": "./dist/types/index.
|
|
76
|
+
"types": "./dist/types/index.d.mts",
|
|
77
|
+
"default": "./dist/types/index.mjs"
|
|
66
78
|
},
|
|
67
79
|
"require": {
|
|
68
80
|
"types": "./dist/types/index.d.cts",
|
|
69
81
|
"default": "./dist/types/index.cjs"
|
|
70
82
|
},
|
|
71
83
|
"default": {
|
|
72
|
-
"types": "./dist/types/index.d.
|
|
73
|
-
"default": "./dist/types/index.
|
|
84
|
+
"types": "./dist/types/index.d.mts",
|
|
85
|
+
"default": "./dist/types/index.mjs"
|
|
74
86
|
}
|
|
75
87
|
},
|
|
76
88
|
"./types/*": {
|
|
77
89
|
"import": {
|
|
78
|
-
"types": "./dist/types/*.d.
|
|
79
|
-
"default": "./dist/types/*.
|
|
90
|
+
"types": "./dist/types/*.d.mts",
|
|
91
|
+
"default": "./dist/types/*.mjs"
|
|
80
92
|
},
|
|
81
93
|
"require": {
|
|
82
94
|
"types": "./dist/types/*.d.cts",
|
|
83
95
|
"default": "./dist/types/*.cjs"
|
|
84
96
|
},
|
|
85
97
|
"default": {
|
|
86
|
-
"types": "./dist/types/*.d.
|
|
87
|
-
"default": "./dist/types/*.
|
|
98
|
+
"types": "./dist/types/*.d.mts",
|
|
99
|
+
"default": "./dist/types/*.mjs"
|
|
88
100
|
}
|
|
89
101
|
},
|
|
90
102
|
"./components": {
|
|
91
103
|
"import": {
|
|
92
|
-
"types": "./dist/components/index.d.
|
|
93
|
-
"default": "./dist/components/index.
|
|
104
|
+
"types": "./dist/components/index.d.mts",
|
|
105
|
+
"default": "./dist/components/index.mjs"
|
|
94
106
|
},
|
|
95
107
|
"require": {
|
|
96
108
|
"types": "./dist/components/index.d.cts",
|
|
97
109
|
"default": "./dist/components/index.cjs"
|
|
98
110
|
},
|
|
99
111
|
"default": {
|
|
100
|
-
"types": "./dist/components/index.d.
|
|
101
|
-
"default": "./dist/components/index.
|
|
112
|
+
"types": "./dist/components/index.d.mts",
|
|
113
|
+
"default": "./dist/components/index.mjs"
|
|
102
114
|
}
|
|
103
115
|
},
|
|
104
116
|
"./components/*": {
|
|
105
117
|
"import": {
|
|
106
|
-
"types": "./dist/components/*.d.
|
|
107
|
-
"default": "./dist/components/*.
|
|
118
|
+
"types": "./dist/components/*.d.mts",
|
|
119
|
+
"default": "./dist/components/*.mjs"
|
|
108
120
|
},
|
|
109
121
|
"require": {
|
|
110
122
|
"types": "./dist/components/*.d.cts",
|
|
111
123
|
"default": "./dist/components/*.cjs"
|
|
112
124
|
},
|
|
113
125
|
"default": {
|
|
114
|
-
"types": "./dist/components/*.d.
|
|
115
|
-
"default": "./dist/components/*.
|
|
126
|
+
"types": "./dist/components/*.d.mts",
|
|
127
|
+
"default": "./dist/components/*.mjs"
|
|
116
128
|
}
|
|
117
129
|
}
|
|
118
130
|
},
|
|
@@ -124,25 +136,24 @@
|
|
|
124
136
|
"react-dom": { "optional": false }
|
|
125
137
|
},
|
|
126
138
|
"dependencies": {
|
|
127
|
-
"@storm-software/config-tools": "^1.188.
|
|
128
|
-
"@stryke/cli": "^0.12.
|
|
129
|
-
"@stryke/convert": "^0.6.
|
|
130
|
-
"@stryke/fs": "^0.33.
|
|
131
|
-
"@stryke/path": "^0.
|
|
139
|
+
"@storm-software/config-tools": "^1.188.52",
|
|
140
|
+
"@stryke/cli": "^0.12.19",
|
|
141
|
+
"@stryke/convert": "^0.6.13",
|
|
142
|
+
"@stryke/fs": "^0.33.9",
|
|
143
|
+
"@stryke/path": "^0.22.0",
|
|
132
144
|
"babel-plugin-react-compiler": "^1.0.0",
|
|
133
|
-
"@powerlines/alloy": "^0.11.
|
|
134
|
-
"@powerlines/plugin-babel": "^0.12.
|
|
135
|
-
"@powerlines/plugin-env": "^0.13.
|
|
136
|
-
"@powerlines/plugin-plugin": "^0.
|
|
145
|
+
"@powerlines/alloy": "^0.11.58",
|
|
146
|
+
"@powerlines/plugin-babel": "^0.12.58",
|
|
147
|
+
"@powerlines/plugin-env": "^0.13.55",
|
|
148
|
+
"@powerlines/plugin-plugin": "^0.12.1",
|
|
137
149
|
"@vitejs/plugin-react": "^5.1.1",
|
|
138
150
|
"defu": "^6.1.4",
|
|
139
|
-
"powerlines": "^0.
|
|
151
|
+
"powerlines": "^0.30.0"
|
|
140
152
|
},
|
|
141
153
|
"devDependencies": {
|
|
142
|
-
"@powerlines/nx": "^0.10.
|
|
143
|
-
"@storm-software/tsup": "^0.2.48",
|
|
154
|
+
"@powerlines/nx": "^0.10.49",
|
|
144
155
|
"@types/node": "^24.10.1"
|
|
145
156
|
},
|
|
146
157
|
"publishConfig": { "access": "public" },
|
|
147
|
-
"gitHead": "
|
|
158
|
+
"gitHead": "f0a4e1526773f5d4bfb63fd5ba1d02d5aa9bc771"
|
|
148
159
|
}
|
package/dist/chunk-FBBMZ4NC.cjs
DELETED
package/dist/chunk-UCUR73HG.js
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export { ReactOptimizedBuiltin, ReactOptimizedBuiltinProps, __ΩReactOptimizedBuiltinProps } from './react-optimized.js';
|
|
2
|
-
import '@alloy-js/core';
|
|
3
|
-
import '@alloy-js/core/jsx-runtime';
|
|
4
|
-
import '../fs-ECFlqnPg.js';
|
|
5
|
-
import '@stryke/fs/resolve';
|
|
6
|
-
import '@stryke/types/base';
|
package/dist/components/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export*from'./react-optimized';
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import * as _alloy_js_core from '@alloy-js/core';
|
|
2
|
-
import { Children as Children$1, SourceFileProps as SourceFileProps$1 } from '@alloy-js/core';
|
|
3
|
-
import { Children } from '@alloy-js/core/jsx-runtime';
|
|
4
|
-
import { a as StoragePreset } from '../fs-ECFlqnPg.js';
|
|
5
|
-
import '@stryke/fs/resolve';
|
|
6
|
-
import '@stryke/types/base';
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* A type that represents the props of a component that can have children.
|
|
10
|
-
*/
|
|
11
|
-
interface ComponentProps {
|
|
12
|
-
children?: Children;
|
|
13
|
-
}
|
|
14
|
-
interface TypescriptFileImportItem {
|
|
15
|
-
name: string;
|
|
16
|
-
default?: boolean;
|
|
17
|
-
alias?: string;
|
|
18
|
-
type?: boolean;
|
|
19
|
-
}
|
|
20
|
-
type TypescriptFileImports = Record<string, null | Array<TypescriptFileImportItem | string>>;
|
|
21
|
-
|
|
22
|
-
interface TSDocModuleProps extends ComponentProps {
|
|
23
|
-
/**
|
|
24
|
-
* the prefix for the builtin module name
|
|
25
|
-
*
|
|
26
|
-
* @defaultValue "storm"
|
|
27
|
-
*/
|
|
28
|
-
prefix?: string;
|
|
29
|
-
/**
|
|
30
|
-
* The name of the module
|
|
31
|
-
*
|
|
32
|
-
* @remarks
|
|
33
|
-
* This will be used in the `@module` tag as well as the import path for the module, e.g. `storm:<name>`.
|
|
34
|
-
*
|
|
35
|
-
* @example
|
|
36
|
-
* ```ts
|
|
37
|
-
* import { MyModule } from "storm:my-module";
|
|
38
|
-
* ```
|
|
39
|
-
*/
|
|
40
|
-
name: Children$1;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
type SourceFileProps = SourceFileProps$1 & ComponentProps & {
|
|
44
|
-
/**
|
|
45
|
-
* If true, indicates that the file is virtual and should not be written to disk.
|
|
46
|
-
*
|
|
47
|
-
* @defaultValue false
|
|
48
|
-
*/
|
|
49
|
-
preset?: StoragePreset;
|
|
50
|
-
/**
|
|
51
|
-
* The metadata associated with the source file.
|
|
52
|
-
*
|
|
53
|
-
* @remarks
|
|
54
|
-
* The values stored in the metadata will be available in the rendering context.
|
|
55
|
-
*/
|
|
56
|
-
meta?: Record<string, any>;
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
type TypescriptFileProps = Omit<SourceFileProps, "filetype"> & ComponentProps & {
|
|
60
|
-
header?: Children$1;
|
|
61
|
-
imports?: TypescriptFileImports;
|
|
62
|
-
export?: boolean | string;
|
|
63
|
-
tsx?: boolean;
|
|
64
|
-
};
|
|
65
|
-
|
|
66
|
-
type BuiltinFileProps = Omit<TypescriptFileProps, "path"> & Omit<TSDocModuleProps, "name"> & {
|
|
67
|
-
/**
|
|
68
|
-
* The runtime module identifier.
|
|
69
|
-
*
|
|
70
|
-
* @remarks
|
|
71
|
-
* This value will be included after the \`storm:\` prefix in the import statement.
|
|
72
|
-
*/
|
|
73
|
-
id: string;
|
|
74
|
-
/**
|
|
75
|
-
* The description for the builtin module.
|
|
76
|
-
*/
|
|
77
|
-
description?: string;
|
|
78
|
-
/**
|
|
79
|
-
* Whether the file is a TSX file.
|
|
80
|
-
*
|
|
81
|
-
* @defaultValue false
|
|
82
|
-
*/
|
|
83
|
-
tsx?: boolean;
|
|
84
|
-
};
|
|
85
|
-
|
|
86
|
-
interface ReactOptimizedBuiltinProps extends Omit<BuiltinFileProps, "id"> {
|
|
87
|
-
override?: boolean;
|
|
88
|
-
}
|
|
89
|
-
/**
|
|
90
|
-
* Generates the `react/optimized` builtin module for the Powerlines project.
|
|
91
|
-
*/
|
|
92
|
-
declare function ReactOptimizedBuiltin(props: ReactOptimizedBuiltinProps): _alloy_js_core.Children;
|
|
93
|
-
declare type __ΩReactOptimizedBuiltinProps = any[];
|
|
94
|
-
|
|
95
|
-
export { ReactOptimizedBuiltin, type ReactOptimizedBuiltinProps, type __ΩReactOptimizedBuiltinProps };
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import {a}from'../chunk-UCUR73HG.js';import {createComponent,mergeProps}from'@alloy-js/core/jsx-runtime';import {splitProps,code}from'@alloy-js/core';import {FunctionDeclaration}from'@alloy-js/typescript';import {usePowerlines}from'@powerlines/alloy/core/contexts/context';import {refkey}from'@powerlines/alloy/helpers/refkey';import {BuiltinFile}from'@powerlines/alloy/typescript/components/builtin-file';import {TSDoc,TSDocLink,TSDocReturns}from'@powerlines/alloy/typescript/components/tsdoc';import h from'defu';/*****************************************
|
|
2
|
-
*
|
|
3
|
-
* ⚡ Built by Storm Software
|
|
4
|
-
*
|
|
5
|
-
*****************************************/
|
|
6
|
-
|
|
7
|
-
const v=refkey("isOptimizationEnabled");function k(n){const[{override:t},i]=splitProps(n,["override"]),c=usePowerlines();return createComponent(BuiltinFile,mergeProps(i,{id:"react/optimized",description:"A built-in module to provide access to environment configuration to determine React optimizations.",get imports(){return h({[`${c?.config.output.builtinPrefix}:env`]:["env","isDevelopment"]},i.imports??{})},get children(){return [createComponent(TSDoc,{heading:"A gating function to determine if the optimized [React compiler](https://react.dev/reference/react-compiler) source code should be used.",get children(){return [createComponent(TSDocLink,{children:"https://react.dev/reference/react-compiler/gating"}),createComponent(TSDocReturns,{children:"A boolean indicating if the React compiler's optimizations should be used."})]}}),createComponent(FunctionDeclaration,{refkey:v,async:false,export:true,name:"isOptimizationEnabled",returnType:"boolean",children:t!==void 0?code`return ${t};`:code`return !env.DISABLE_REACT_COMPILER && !isDevelopment; `})]}}))}a(k,"ReactOptimizedBuiltin");
|
|
8
|
-
export{k as ReactOptimizedBuiltin};
|