@tanstack/cta-framework-react-cra 0.22.3 → 0.23.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.
@@ -1,11 +1,24 @@
1
1
  ## Setting up Netlify
2
2
 
3
- First install the Netlify CLI with:
3
+ Install the [`@netlify/vite-plugin-tanstack-start`](https://www.npmjs.com/package/@netlify/vite-plugin-tanstack-start) plugin:
4
4
 
5
5
  ```bash
6
- npm install -g netlify-cli`
6
+ npm install -D @netlify/vite-plugin-tanstack-start
7
7
  ```
8
8
 
9
- ```bash
10
- netlify init
9
+ Add the plugin to your `vite.config.ts`:
10
+
11
+ ```ts
12
+ import netlify from '@netlify/vite-plugin-tanstack-start'
13
+
14
+ export default defineConfig({
15
+ plugins: [
16
+ // ... your existing plugins
17
+ netlify(),
18
+ ],
19
+ })
11
20
  ```
21
+
22
+ A `netlify.toml` file has been automatically created for you with the correct build settings.
23
+
24
+ That's it. You can now deploy your app [from Netlify UI](https://docs.netlify.com/start/add-new-project/#import-from-an-existing-repository) or with the [Netlify CLI](https://docs.netlify.com/api-and-cli-guides/cli-guides/get-started-with-cli/#manual-deploys).
@@ -0,0 +1,6 @@
1
+ [build]
2
+ command = "vite build"
3
+ dir = "dist/client"
4
+ [dev]
5
+ command = "vite dev"
6
+ port = 3000
@@ -2,7 +2,7 @@ import { createRouterClient } from '@orpc/server'
2
2
  import { createORPCClient } from '@orpc/client'
3
3
  import { RPCLink } from '@orpc/client/fetch'
4
4
  import { createTanstackQueryUtils } from '@orpc/tanstack-query'
5
- import { getHeaders } from '@tanstack/react-start/server'
5
+ import { getRequestHeaders } from '@tanstack/react-start/server'
6
6
  import { createIsomorphicFn } from '@tanstack/react-start'
7
7
 
8
8
  import type { RouterClient } from '@orpc/server'
@@ -13,7 +13,7 @@ const getORPCClient = createIsomorphicFn()
13
13
  .server(() =>
14
14
  createRouterClient(router, {
15
15
  context: () => ({
16
- headers: getHeaders(),
16
+ headers: getRequestHeaders(),
17
17
  }),
18
18
  }),
19
19
  )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanstack/cta-framework-react-cra",
3
- "version": "0.22.3",
3
+ "version": "0.23.0",
4
4
  "description": "CTA Framework for React (Create React App)",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -23,7 +23,7 @@
23
23
  "author": "Jack Herrington <jherr@pobox.com>",
24
24
  "license": "MIT",
25
25
  "dependencies": {
26
- "@tanstack/cta-engine": "0.22.3"
26
+ "@tanstack/cta-engine": "0.23.0"
27
27
  },
28
28
  "devDependencies": {
29
29
  "@types/node": "^22.13.4",