Ben Holmes
d10f91815e
Actions middleware ( #12373 )
...
* add manual middleware config option with getMiddlewareContext()
* refactor requestInfo to action object
* set action error response status from render context
* update automatic middleware to plain POST handler
* fix missing Locals type
* test: add separate POST and cookie forwarding tests
* remove actions.middleware flag
* add docs on actionResultAlreadySet
* test: use Astro.rewrite instead of middleware next(). TODO: fix next()
* fix type errors from rebase
* test: remove middleware handler
* test: use cookie forwarding for 'lots of fields'
* refactor: _isPrerendered -> ctx.isPrerendered
* expose getOriginPathname as middleware utility
* add support for handling RPC action results from middleware
* test: RPC security middleware
* refactor POST route handler to use getMiddlewareContext()
* remove unused actionRedirect flag
* changeset
* test: add expectedd rewrite failure for Ema to debug
* fix e2e test
* nit: form -> from
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
* rename getMiddlewareContext -> getActionContext
* rename form-action -> form
* move /_actions/ route pattern to const
* move type defs to user-accessible ActionMiddlewareContext type
* export action middleware context type
* strip omitted fields for Action API Context
* add satisfies to type for good measure
* move getOriginPathname to shared ctx.originPathname
* remove `next()` rewrite because it isn't supported
* fix empty forms raising a 415
* fix missing async on cookie example
* nit: ctx -> context
* fix json parse error when content length is 0
* refactor body parsing to function
* edit: migration -> updating your HTML form actions
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
* update changeset to match docs v5 guide
* add absolute urls to changeset links
---------
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
2024-11-08 17:03:57 -05:00
Ben Holmes
9cca108439
Fix incorrect status code in dev server for action errors ( #12401 )
...
* remove default status that swallows response.status
* refactor status compute to be more readable
* changeset
2024-11-08 14:06:19 -05:00
Emanuele Stoppa
823e73b164
fix(actions): better runtime check for invalid usages ( #12402 )
2024-11-08 15:55:53 +00:00
Florian Lefebvre
f5f71094ec
fix: error overlay message escape ( #12305 )
...
Co-authored-by: Princesseuh <3019731+Princesseuh@users.noreply.github.com>
2024-11-08 16:07:40 +01:00
Houston (Bot)
d63d87dcae
[ci] release (beta) ( #12370 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-06 23:47:57 +08:00
bluwy
b21a075002
Add svelte changeset
2024-11-06 23:34:10 +08:00
bluwy
7db86cf2b7
Merge branch 'main' into next
2024-11-06 23:17:39 +08:00
Houston (Bot)
e10b03e88c
[ci] release ( #12369 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-06 22:55:41 +08:00
Bjorn Lu
c280655655
Update to Vite 6.0.0-beta.6 ( #12323 )
2024-11-06 22:51:55 +08:00
Bjorn Lu
4a35c505e4
[ci] format
2024-11-06 14:16:10 +00:00
Bjorn Lu
6fd3d5960f
Add support for Svelte 5 @render syntax ( #12390 )
...
Co-authored-by: Jonas Robertsson <jonas.robertsson@icloud.com>
2024-11-06 22:09:22 +08:00
renovate[bot]
b7e46910fb
fix(deps): update all non-major dependencies ( #12366 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: bluwy <bjornlu.dev@gmail.com>
2024-11-06 21:47:42 +08:00
Erika
94f4fe8180
Adds missing changeset for new basics template ( #12379 )
2024-11-06 21:32:27 +08:00
Sujal Gurung
bf2723e831
add checked
to htmlBooleanAttributes ( #12311 )
...
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2024-11-06 13:32:05 +00:00
Arpan Patel
c4726d7ba8
fix: show file name with invalid frontmatter errors for MDX ( #12355 )
...
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
Co-authored-by: Princesseuh <3019731+Princesseuh@users.noreply.github.com>
2024-11-06 21:22:38 +08:00
Emanuele Stoppa
4c9a42c2da
[ci] format
2024-11-06 12:34:13 +00:00
Emanuele Stoppa
ed5a9f1b75
chore: codspeed benchmark ( #12347 )
2024-11-06 12:33:14 +00:00
Luiz Ferraz
222f71894c
Fix astro add
generated import identifier ( #12363 )
2024-11-06 14:16:34 +08:00
Erika
9263e96593
create-astro updates ( #12083 )
...
Co-authored-by: Reuben Tier <64310361+TheOtterlord@users.noreply.github.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
Co-authored-by: Florian Lefebvre <contact@florian-lefebvre.dev>
Co-authored-by: Reuben Tier <otterlord.dev@gmail.com>
2024-11-04 16:15:11 +01:00
Bjorn Lu
493fe43cd3
Improve tinyexec errors ( #12368 )
2024-11-04 22:49:33 +08:00
Houston (Bot)
ec3113d25a
[ci] release ( #12345 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-04 15:20:48 +01:00
Paul Welsh
7680349873
fix: honor getViteConfig inlineAstroConfig.logLevel setting ( #12358 )
...
Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
2024-11-04 10:01:09 +00:00
Hippo
35795a1a54
Fix watchfile multiple dev server restart ( #12353 )
2024-11-04 16:19:54 +08:00
Florian Lefebvre
5751488165
fix: revert #12227 ( #12351 )
2024-11-01 16:53:15 +01:00
Vladislav Mamon
c480b8f2c4
[ci] format
2024-11-01 10:50:42 +00:00
Vladislav Mamon
1fc83d3ba8
fix(assets): fix getImage
options type ( #12349 )
2024-11-01 11:49:55 +01:00
Bjorn Lu
20e5a843c8
Fix prefetch sourcemap generation ( #12346 )
2024-11-01 16:01:19 +08:00
Matt Callaway
836cd91c37
fix: Destroy the node http server response stream if there was a caught error ( #12333 )
2024-10-31 13:47:32 +00:00
Houston (Bot)
731b69712b
[ci] release (beta) ( #12250 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-31 17:07:35 +08:00
bluwy
d879c02a26
Fix merge error
2024-10-31 16:29:56 +08:00
bluwy
81b0bf5734
Add changeset for vue to include changes from 4.5.2
...
closes #12289
2024-10-31 16:19:21 +08:00
bluwy
63b4ab95b9
Merge branch 'main' into next
2024-10-31 16:16:00 +08:00
Houston (Bot)
5f7bf49d38
[ci] release ( #12290 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-31 15:56:38 +08:00
liruifengv
ffc836bac0
Fix cli command typo ( #12342 )
...
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2024-10-31 15:51:39 +08:00
situ2001
c414eec6ac
[ci] format
2024-10-31 03:14:42 +00:00
situ2001
9ca89b3e13
fix(cli): reset NODE_ENV
to ensure install command run in dev mode ( #12338 )
2024-10-31 11:13:50 +08:00
Emanuele Stoppa
c1786d64c4
fix(i18n): default locale in server islands ( #12341 )
2024-10-30 19:38:10 +00:00
Emanuele Stoppa
94eaeea1c4
chore: add changeset for #12280 ( #12340 )
2024-10-30 11:57:23 +00:00
Fredrik Löwenhamn
e2056c218e
[ci] format
2024-10-30 11:56:26 +00:00
Fredrik Löwenhamn
ea85546487
Fix base not working with server actions ( #12280 )
...
Co-authored-by: Fredrik Löwenhamn <fredrik.lowenhamn@gmail.com>
2024-10-30 11:55:39 +00:00
Emanuele Stoppa
25192a0599
fix(routing): match against decoded pathname ( #12270 )
2024-10-30 11:45:42 +00:00
Sarah Rainsberger
413503e52c
Update image error messages ( #12331 )
...
Co-authored-by: Atharva <atharvapise19@gmail.com>
2024-10-29 12:17:11 -03:00
Sarah Rainsberger
5376acf082
Update link in error message ( #12334 )
2024-10-29 11:13:05 -03:00
koyopro
feb87c21be
[ci] format
2024-10-29 04:15:08 +00:00
koyopro
5642ef9029
Fix: The problem getViteConfig() duplicates some config ( #12312 )
...
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
Co-authored-by: bluwy <bjornlu.dev@gmail.com>
2024-10-29 12:14:20 +08:00
Arpan Patel
0cfc69d499
fix(actions): pass actionAPIContext to action handler instead of APIContext ( #12301 )
...
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2024-10-28 22:10:18 +08:00
renovate[bot]
ecc4402b3a
fix(deps): update all non-major dependencies ( #12316 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-10-28 22:00:15 +08:00
Sarah Rainsberger
e482762cb2
[docs] update a link in error reference ( #12298 )
2024-10-25 17:35:45 -03:00
Emanuele Stoppa
7196c244ea
fix(routing): don't check headers for prenredered pages ( #12302 )
2024-10-25 15:16:54 +01:00
Emanuele Stoppa
4e9a3ac0bd
feat: update astro add vercel
( #12268 )
2024-10-25 14:17:36 +01:00