@rsc-kit/mcp 0.41.0 → 0.42.1
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/recipes.js +18 -2
- package/dist/recipes.js.map +1 -1
- package/guides/admin-plugins.md +206 -6
- package/guides/api-routes.md +159 -215
- package/guides/authorization.md +103 -114
- package/guides/backend-answered-pages.md +301 -252
- package/guides/bap-vs-inertia.md +67 -25
- package/guides/blueprints.md +300 -169
- package/guides/bun.md +42 -25
- package/guides/caching.md +46 -49
- package/guides/coming-from-inertia.md +2 -2
- package/guides/commands.md +251 -200
- package/guides/connection.md +50 -54
- package/guides/content-security-policy.md +133 -84
- package/guides/domains.md +190 -149
- package/guides/edge-caching.md +242 -268
- package/guides/emails.md +96 -45
- package/guides/errors.md +116 -137
- package/guides/feature-flags.md +100 -30
- package/guides/file-uploads.md +101 -26
- package/guides/fonts.md +139 -110
- package/guides/forms.md +520 -542
- package/guides/images.md +87 -28
- package/guides/index.json +13 -33
- package/guides/instrumentation.md +134 -95
- package/guides/isr.md +3 -3
- package/guides/live-data-in-production.md +695 -0
- package/guides/live-data.md +170 -839
- package/guides/mcp.md +83 -59
- package/guides/metadata.md +124 -179
- package/guides/navigation.md +118 -147
- package/guides/no-javascript.md +49 -57
- package/guides/offline.md +118 -153
- package/guides/openapi.md +100 -35
- package/guides/pages.md +160 -50
- package/guides/ppr.md +178 -256
- package/guides/pwa.md +270 -216
- package/guides/queries.md +171 -300
- package/guides/react-compiler.md +90 -50
- package/guides/redirects.md +141 -177
- package/guides/response-headers.md +76 -74
- package/guides/route-interception.md +112 -111
- package/guides/routing.md +216 -322
- package/guides/sections.md +63 -66
- package/guides/seo-files.md +127 -65
- package/guides/server-actions.md +285 -357
- package/guides/static-generation.md +131 -199
- package/guides/testing.md +269 -147
- package/guides/third-party-scripts.md +94 -47
- package/guides/typed-routes.md +115 -113
- package/guides/url-validation.md +113 -61
- package/guides/validation.md +53 -62
- package/guides/view-transitions.md +159 -132
- package/guides/where-it-runs.md +226 -162
- package/package.json +2 -2
- package/guides/admin.md +0 -520
- package/guides/deployment.md +0 -598
- package/guides/go.md +0 -539
- package/guides/laravel.md +0 -787
- package/guides/your-own-backend.md +0 -602
package/dist/recipes.js
CHANGED
|
@@ -114,6 +114,16 @@ A wizard keeps every step's fields in the form (hidden, not unmounted) and does
|
|
|
114
114
|
\`onClick={async () => (await validate('email')) && setStep(2)}\`. Checking as
|
|
115
115
|
it is typed is validate() in onChange - debounce it yourself.
|
|
116
116
|
|
|
117
|
+
STOPPING BOTS: put <Honeypot /> (import { Honeypot } from '@rsc-kit/core/honeypot')
|
|
118
|
+
inside any form that posts to a server action - <Form>, a plain <form action>,
|
|
119
|
+
with or without JS, a "use server" function or a Laravel/Go action. A post with
|
|
120
|
+
its hidden field filled is answered as a success and dropped BEFORE the action
|
|
121
|
+
runs; the trap is stripped otherwise, so the action never sees it. The field is
|
|
122
|
+
'homepage'; <Honeypot name="website" /> renames it. Forms without it are not
|
|
123
|
+
checked. Crude spam only - add a rate limit (Laravel: throttle middleware on
|
|
124
|
+
the action class) for a form worth attacking. Do NOT hand-roll a hidden input
|
|
125
|
+
and check it in the action.
|
|
126
|
+
|
|
117
127
|
Values are uncontrolled, so an initial one is React's own \`defaultValue\`. A
|
|
118
128
|
refused submit keeps what was typed, because the DOM kept it.
|
|
119
129
|
|
|
@@ -1295,6 +1305,12 @@ css, fonts, manifest, icons, / and /offline with their boot payloads; images,
|
|
|
1295
1305
|
wasm and the share card are cached on first use. A frozen page never visited
|
|
1296
1306
|
falls back to /offline like any other navigation. Do not add a second service
|
|
1297
1307
|
worker or a precache list; app/sw.js is importScripts'd into this one.
|
|
1308
|
+
MOVING DOMAIN (www -> bare, old -> new): redirect everything on the old
|
|
1309
|
+
origin EXCEPT /sw.js, which the app keeps serving there for a few weeks. A
|
|
1310
|
+
browser never updates a worker whose script redirects, so without the
|
|
1311
|
+
exception a returning visitor's worker serves the old origin's stored pages
|
|
1312
|
+
and the offline page instead of the redirect. From 0.42.1 the worker also
|
|
1313
|
+
leaves on its own when a request fails because its url now redirects.
|
|
1298
1314
|
|
|
1299
1315
|
An action that redirect()s RESOLVES with { redirected: '/where' } on the
|
|
1300
1316
|
client once the navigation starts - it does not throw, so a plain
|
|
@@ -2411,7 +2427,7 @@ ROTATING is a deploy:
|
|
|
2411
2427
|
- signing: open pages stop refreshing until reloaded; nothing else breaks.
|
|
2412
2428
|
- action key: actions from pages loaded before the change fail.
|
|
2413
2429
|
|
|
2414
|
-
Docs: /hosts/deployment
|
|
2430
|
+
Docs: /hosts/deployment/secrets/.`,
|
|
2415
2431
|
},
|
|
2416
2432
|
{
|
|
2417
2433
|
topic: 'env',
|
|
@@ -3216,7 +3232,7 @@ which is the renderer's runtime.
|
|
|
3216
3232
|
|
|
3217
3233
|
A THEME draws it with one component, BlueprintForm (type FormsTheme from
|
|
3218
3234
|
@rsc-kit/press/forms), given action, fields, values, submit, done and
|
|
3219
|
-
honeypot; replace it with theme: { ...shadcn, BlueprintForm: Mine }.
|
|
3235
|
+
honeypot (render <Honeypot name={honeypot} /> from @rsc-kit/core/honeypot); replace it with theme: { ...shadcn, BlueprintForm: Mine }.
|
|
3220
3236
|
VISIBLE: fields: { company: { visible: { when: 'topic', is: 'sales' } } }
|
|
3221
3237
|
shows a field only while another has one of the values in is (one or a
|
|
3222
3238
|
list); not turns it round; neither means once the other is filled in or
|