@react-router/dev 7.15.1 → 8.0.0-pre.0
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/CHANGELOG.md +18 -0
- package/bin.cjs +20 -0
- package/dist/build-DM91F_L-.js +41 -0
- package/dist/cli/index.d.ts +2 -1
- package/dist/cli/index.js +378 -2591
- package/dist/config-DvmRcD4Z.d.ts +279 -0
- package/dist/config.d.ts +2 -280
- package/dist/config.js +2 -19
- package/dist/dev-CNEgIjT-.js +53 -0
- package/dist/routes-DXogguGb.js +194 -0
- package/dist/{routes-CZR-bKRt.d.ts → routes-Kx8VZRs3.d.ts} +63 -62
- package/dist/routes.d.ts +3 -2
- package/dist/routes.js +3 -190
- package/dist/typegen-BLMwBSoM.js +859 -0
- package/dist/vite.d.ts +7 -6
- package/dist/vite.js +3225 -6492
- package/module-sync-enabled/index.mjs +2 -2
- package/package.json +53 -59
- package/bin.js +0 -15
- package/dist/vite/cloudflare.d.ts +0 -24
- package/dist/vite/cloudflare.js +0 -891
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# `@react-router/dev`
|
|
2
2
|
|
|
3
|
+
## v7.16.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- Stabilize `future.unstable_trailingSlashAwareDataRequests` as `future.v8_trailingSlashAwareDataRequests` ([#15098](https://github.com/remix-run/react-router/pull/15098))
|
|
8
|
+
- The unstable flag is no longer supported and will error during config resolution
|
|
9
|
+
|
|
10
|
+
- Log future flag warnings for upcoming React Router v8 flags ([#15029](https://github.com/remix-run/react-router/pull/15029))
|
|
11
|
+
- `v8_middleware`, `v8_splitRouteModules`, `v8_viteEnvironmentApi`, `v8_passThroughRequests`, `v8_trailingSlashAwareDataRequests`
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies:
|
|
16
|
+
- [`react-router@7.16.0`](https://github.com/remix-run/react-router/releases/tag/react-router@7.16.0)
|
|
17
|
+
- [`@react-router/node@7.16.0`](https://github.com/remix-run/react-router/releases/tag/@react-router/node@7.16.0)
|
|
18
|
+
- [`@react-router/serve@7.16.0`](https://github.com/remix-run/react-router/releases/tag/@react-router/serve@7.16.0)
|
|
19
|
+
|
|
3
20
|
## v7.15.1
|
|
4
21
|
|
|
5
22
|
### Patch Changes
|
|
@@ -11,6 +28,7 @@
|
|
|
11
28
|
strip the base prefix from server-build virtual module import paths, causing
|
|
12
29
|
"Failed to load url /root.tsx" errors. The fix uses `/@fs/` absolute paths
|
|
13
30
|
for those imports to bypass Vite's base-stripping logic.
|
|
31
|
+
|
|
14
32
|
- Updated dependencies:
|
|
15
33
|
- [`react-router@7.15.1`](https://github.com/remix-run/react-router/releases/tag/react-router@7.15.1)
|
|
16
34
|
- [`@react-router/node@7.15.1`](https://github.com/remix-run/react-router/releases/tag/@react-router/node@7.15.1)
|
package/bin.cjs
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
void (async () => {
|
|
3
|
+
let { default: arg } = await import("arg");
|
|
4
|
+
|
|
5
|
+
// Minimal replication of our actual parsing in `run.ts`. If not already set,
|
|
6
|
+
// default `NODE_ENV` so React loads the proper version in its CJS entry script.
|
|
7
|
+
// We have to do this before importing `run.ts` since that is what imports
|
|
8
|
+
// `react` (indirectly via `react-router`)
|
|
9
|
+
let args = arg({}, { argv: process.argv.slice(2), permissive: true });
|
|
10
|
+
if (args._.length === 0 || args._[0] === "dev") {
|
|
11
|
+
process.env.NODE_ENV = process.env.NODE_ENV ?? "development";
|
|
12
|
+
} else {
|
|
13
|
+
process.env.NODE_ENV = process.env.NODE_ENV ?? "production";
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
await import("./dist/cli/index.js");
|
|
17
|
+
})().catch((error) => {
|
|
18
|
+
if (error) console.error(error);
|
|
19
|
+
process.exit(1);
|
|
20
|
+
});
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @react-router/dev v8.0.0-pre.0
|
|
3
|
+
*
|
|
4
|
+
* Copyright (c) Remix Software Inc.
|
|
5
|
+
*
|
|
6
|
+
* This source code is licensed under the MIT license found in the
|
|
7
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
8
|
+
*
|
|
9
|
+
* @license MIT
|
|
10
|
+
*/
|
|
11
|
+
import { g as preloadVite, h as getVite } from "./typegen-BLMwBSoM.js";
|
|
12
|
+
//#region vite/build.ts
|
|
13
|
+
async function build(root, viteBuildOptions) {
|
|
14
|
+
await preloadVite();
|
|
15
|
+
let { assetsInlineLimit, clearScreen, config: configFile, emptyOutDir, force, logLevel, minify, mode, sourcemapClient, sourcemapServer } = viteBuildOptions;
|
|
16
|
+
await (await getVite().createBuilder({
|
|
17
|
+
root,
|
|
18
|
+
mode,
|
|
19
|
+
configFile,
|
|
20
|
+
build: {
|
|
21
|
+
assetsInlineLimit,
|
|
22
|
+
emptyOutDir,
|
|
23
|
+
minify
|
|
24
|
+
},
|
|
25
|
+
optimizeDeps: { force },
|
|
26
|
+
clearScreen,
|
|
27
|
+
logLevel,
|
|
28
|
+
plugins: [{
|
|
29
|
+
name: "react-router:cli-config",
|
|
30
|
+
configEnvironment(name) {
|
|
31
|
+
if (sourcemapClient && name === "client") return { build: { sourcemap: sourcemapClient } };
|
|
32
|
+
if (sourcemapServer && name !== "client") return { build: { sourcemap: sourcemapServer } };
|
|
33
|
+
},
|
|
34
|
+
configResolved(config) {
|
|
35
|
+
if (!config.plugins.find((plugin) => plugin.name === "react-router" || plugin.name === "react-router/rsc")) throw new Error("React Router Vite plugin not found in Vite config");
|
|
36
|
+
}
|
|
37
|
+
}]
|
|
38
|
+
})).buildApp();
|
|
39
|
+
}
|
|
40
|
+
//#endregion
|
|
41
|
+
export { build };
|
package/dist/cli/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
export { };
|