-
Notifications
You must be signed in to change notification settings - Fork 991
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(prerender): build with esbuild and introduce conditional exp…
…orts (#11337) Switches the prerender package to be built with esbuild rather than babel. This change doesn't not use module or moduleResolution Node16 in the build version of the tsconfig. This is because it would pick up cjs/esm issues with apollo and vite. I will look to follow up with fixes that can enable us to use the modern settings in the build version also.
- Loading branch information
1 parent
68b37fa
commit b544605
Showing
11 changed files
with
64 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
- refactor(prerender): build with esbuild and introduce conditional exports (#11337) by @Josh-Walker-GM | ||
|
||
This change restricts the available imports from the `@redwoodjs/prerender` package. You will also have to use modern `moduleResolution` settings in your tsconfig to resolve the imports correctly within TS. |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { build } from '@redwoodjs/framework-tools' | ||
|
||
await build() |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"extends": "../../tsconfig.compilerOption.json", | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist", | ||
"allowJs": true | ||
}, | ||
"include": ["./src/**/*", "ambient.d.ts"], | ||
"references": [ | ||
{ "path": "../babel-config" }, | ||
{ "path": "../project-config" }, | ||
{ "path": "../router/tsconfig.build.json" }, | ||
{ "path": "../structure" }, | ||
{ "path": "../web/tsconfig.build.json" }, | ||
{ "path": "../framework-tools" } | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,18 @@ | ||
{ | ||
"extends": "../../tsconfig.compilerOption.json", | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist", | ||
"module": "Node16", | ||
"moduleResolution": "Node16", | ||
"allowJs": true | ||
}, | ||
"include": ["./src/**/*", "ambient.d.ts"], | ||
"include": ["."], | ||
"references": [ | ||
{ "path": "../web/tsconfig.build.json" }, | ||
{ "path": "../router/tsconfig.build.json" }, | ||
{ "path": "../internal" }, | ||
{ "path": "../babel-config" }, | ||
{ "path": "../project-config" }, | ||
{ "path": "../auth/tsconfig.build.json" }, | ||
{ "path": "../structure" } | ||
] | ||
{ "path": "../router/tsconfig.build.json" }, | ||
{ "path": "../structure" }, | ||
{ "path": "../web/tsconfig.build.json" }, | ||
{ "path": "../framework-tools" } | ||
], | ||
"exclude": ["dist", "node_modules", "**/__mocks__", "**/__tests__/fixtures"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters