@cedarjs/vite 6.0.0-canary.2690 → 6.0.0-canary.2691
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/dist/cjs/index.js +8 -8
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -8
- package/package.json +14 -14
package/dist/cjs/index.js
CHANGED
|
@@ -59,7 +59,6 @@ module.exports = __toCommonJS(index_exports);
|
|
|
59
59
|
var import_plugin_react = __toESM(require("@vitejs/plugin-react"), 1);
|
|
60
60
|
var import_vite_plugin_graphql_tag = require("vite-plugin-graphql-tag");
|
|
61
61
|
var import_vite_tsconfig_paths = __toESM(require("vite-tsconfig-paths"), 1);
|
|
62
|
-
var import_babel_config = require("@cedarjs/babel-config");
|
|
63
62
|
var import_project_config = require("@cedarjs/project-config");
|
|
64
63
|
var import_vitest = require("@cedarjs/testing/web/vitest");
|
|
65
64
|
var import_vite_plugin_cedar_auto_import = require("./plugins/vite-plugin-cedar-auto-import.js");
|
|
@@ -104,15 +103,16 @@ const tsconfigPaths = (
|
|
|
104
103
|
// interop
|
|
105
104
|
import_vite_tsconfig_paths.default.default?.default || import_vite_tsconfig_paths.default.default || import_vite_tsconfig_paths.default
|
|
106
105
|
);
|
|
107
|
-
function cedar({ mode } = {}) {
|
|
106
|
+
function cedar({ mode, babel } = {}) {
|
|
108
107
|
const cedarConfig = (0, import_project_config.getConfig)();
|
|
109
108
|
const rscEnabled = cedarConfig.experimental?.rsc?.enabled;
|
|
110
|
-
const
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
109
|
+
const reactCompilerEnabled = cedarConfig.experimental?.reactCompiler?.enabled && cedarConfig.experimental?.reactCompiler?.lintOnly === false;
|
|
110
|
+
const babelConfig = reactCompilerEnabled || babel ? {
|
|
111
|
+
...reactCompilerEnabled && {
|
|
112
|
+
plugins: [["babel-plugin-react-compiler", { target: "19" }]]
|
|
113
|
+
},
|
|
114
|
+
...babel
|
|
115
|
+
} : void 0;
|
|
116
116
|
return [
|
|
117
117
|
tsconfigPaths(),
|
|
118
118
|
(0, import_vite_plugin_graphql_tag.gqlPlugin)(),
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { BabelOptions } from '@vitejs/plugin-react';
|
|
1
2
|
import type { PluginOption } from 'vite';
|
|
2
3
|
export { cedarAutoImportsPlugin } from './plugins/vite-plugin-cedar-auto-import.js';
|
|
3
4
|
export { cedarCjsCompatPlugin } from './plugins/vite-plugin-cedar-cjs-compat.js';
|
|
@@ -24,11 +25,12 @@ export { cedarUniversalDeployPlugin } from './plugins/vite-plugin-cedar-universa
|
|
|
24
25
|
export { cedarWaitForApiServer } from './plugins/vite-plugin-cedar-wait-for-api-server.js';
|
|
25
26
|
type PluginOptions = {
|
|
26
27
|
mode?: string | undefined;
|
|
28
|
+
babel?: BabelOptions | undefined;
|
|
27
29
|
};
|
|
28
30
|
/**
|
|
29
31
|
* Pre-configured vite plugin, with required config for CedarJS apps.
|
|
30
32
|
*/
|
|
31
|
-
export declare function cedar({ mode }?: PluginOptions): PluginOption[];
|
|
33
|
+
export declare function cedar({ mode, babel }?: PluginOptions): PluginOption[];
|
|
32
34
|
/** @deprecated Please use the named `cedar` export instead */
|
|
33
35
|
export default cedar;
|
|
34
36
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,MAAM,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACxD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,MAAM,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,oDAAoD,CAAA;AAE1F,KAAK,aAAa,GAAG;IACnB,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IACzB,KAAK,CAAC,EAAE,YAAY,GAAG,SAAS,CAAA;CACjC,CAAA;AAED;;GAEG;AACH,wBAAgB,KAAK,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,GAAE,aAAkB,GAAG,YAAY,EAAE,CA0CzE;AAED,8DAA8D;AAC9D,eAAe,KAAK,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -6,7 +6,6 @@ const tsconfigPaths = (
|
|
|
6
6
|
// interop
|
|
7
7
|
tsPathsMod.default?.default || tsPathsMod.default || tsPathsMod
|
|
8
8
|
);
|
|
9
|
-
import { getWebSideDefaultBabelConfig } from "@cedarjs/babel-config";
|
|
10
9
|
import { getConfig } from "@cedarjs/project-config";
|
|
11
10
|
import {
|
|
12
11
|
autoImportsPlugin,
|
|
@@ -53,15 +52,16 @@ import { cedarMergedConfig as cedarMergedConfig2 } from "./plugins/vite-plugin-m
|
|
|
53
52
|
import { cedarSwapApolloProvider as cedarSwapApolloProvider2 } from "./plugins/vite-plugin-swap-apollo-provider.js";
|
|
54
53
|
import { cedarUniversalDeployPlugin } from "./plugins/vite-plugin-cedar-universal-deploy.js";
|
|
55
54
|
import { cedarWaitForApiServer as cedarWaitForApiServer2 } from "./plugins/vite-plugin-cedar-wait-for-api-server.js";
|
|
56
|
-
function cedar({ mode } = {}) {
|
|
55
|
+
function cedar({ mode, babel } = {}) {
|
|
57
56
|
const cedarConfig = getConfig();
|
|
58
57
|
const rscEnabled = cedarConfig.experimental?.rsc?.enabled;
|
|
59
|
-
const
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
58
|
+
const reactCompilerEnabled = cedarConfig.experimental?.reactCompiler?.enabled && cedarConfig.experimental?.reactCompiler?.lintOnly === false;
|
|
59
|
+
const babelConfig = reactCompilerEnabled || babel ? {
|
|
60
|
+
...reactCompilerEnabled && {
|
|
61
|
+
plugins: [["babel-plugin-react-compiler", { target: "19" }]]
|
|
62
|
+
},
|
|
63
|
+
...babel
|
|
64
|
+
} : void 0;
|
|
65
65
|
return [
|
|
66
66
|
tsconfigPaths(),
|
|
67
67
|
gqlTagPlugin(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cedarjs/vite",
|
|
3
|
-
"version": "6.0.0-canary.
|
|
3
|
+
"version": "6.0.0-canary.2691",
|
|
4
4
|
"description": "Vite configuration package for CedarJS",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -63,16 +63,16 @@
|
|
|
63
63
|
"@babel/parser": "7.29.7",
|
|
64
64
|
"@babel/traverse": "7.29.7",
|
|
65
65
|
"@babel/types": "7.29.7",
|
|
66
|
-
"@cedarjs/api": "6.0.0-canary.
|
|
67
|
-
"@cedarjs/api-server": "6.0.0-canary.
|
|
68
|
-
"@cedarjs/babel-config": "6.0.0-canary.
|
|
69
|
-
"@cedarjs/context": "6.0.0-canary.
|
|
70
|
-
"@cedarjs/cookie-jar": "6.0.0-canary.
|
|
71
|
-
"@cedarjs/graphql-server": "6.0.0-canary.
|
|
72
|
-
"@cedarjs/internal": "6.0.0-canary.
|
|
73
|
-
"@cedarjs/project-config": "6.0.0-canary.
|
|
74
|
-
"@cedarjs/server-store": "6.0.0-canary.
|
|
75
|
-
"@cedarjs/testing": "6.0.0-canary.
|
|
66
|
+
"@cedarjs/api": "6.0.0-canary.2691",
|
|
67
|
+
"@cedarjs/api-server": "6.0.0-canary.2691",
|
|
68
|
+
"@cedarjs/babel-config": "6.0.0-canary.2691",
|
|
69
|
+
"@cedarjs/context": "6.0.0-canary.2691",
|
|
70
|
+
"@cedarjs/cookie-jar": "6.0.0-canary.2691",
|
|
71
|
+
"@cedarjs/graphql-server": "6.0.0-canary.2691",
|
|
72
|
+
"@cedarjs/internal": "6.0.0-canary.2691",
|
|
73
|
+
"@cedarjs/project-config": "6.0.0-canary.2691",
|
|
74
|
+
"@cedarjs/server-store": "6.0.0-canary.2691",
|
|
75
|
+
"@cedarjs/testing": "6.0.0-canary.2691",
|
|
76
76
|
"@fastify/url-data": "6.0.3",
|
|
77
77
|
"@swc/core": "1.15.41",
|
|
78
78
|
"@universal-deploy/store": "^0.2.1",
|
|
@@ -109,9 +109,9 @@
|
|
|
109
109
|
},
|
|
110
110
|
"devDependencies": {
|
|
111
111
|
"@arethetypeswrong/cli": "0.18.5",
|
|
112
|
-
"@cedarjs/auth": "6.0.0-canary.
|
|
113
|
-
"@cedarjs/router": "6.0.0-canary.
|
|
114
|
-
"@cedarjs/web": "6.0.0-canary.
|
|
112
|
+
"@cedarjs/auth": "6.0.0-canary.2691",
|
|
113
|
+
"@cedarjs/router": "6.0.0-canary.2691",
|
|
114
|
+
"@cedarjs/web": "6.0.0-canary.2691",
|
|
115
115
|
"@hyrious/esbuild-plugin-commonjs": "0.2.6",
|
|
116
116
|
"@jridgewell/trace-mapping": "0.3.31",
|
|
117
117
|
"@types/aws-lambda": "8.10.162",
|