-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Actions: New fallback behavior with action={actions.name}
#11570
Conversation
🦋 Changeset detectedLatest commit: 91ddd65 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is blocked because it contains a minor
changeset. A reviewer will merge this at the next release if approved.
Reason for the minor: this is a breaking change for the React integration. It's otherwise non-breaking since |
My only pause here is will people understand that the POST will return to this current Astro page? I might find that confusing without knowing. I guess if people do then we could add the |
8cf7709
to
c3440a2
Compare
@matthewp Totally understand the concern. This API was chosen due to the precedent React and SvelteKit have set for actions returning to the current page. I'd expect the pattern to feel nicer for our majority userbase. We are waiting another 2 weeks for a minor release, so that should give us time to get user feedback on the change. I will also rework the RFC docs to better explain the pattern for those that (inevitably) use this in a |
Changes
Introduce the new pattern
action={actions.name}
for form fallbacks. This replaces the previousgetActionProps()
pattern.getActionProps()
.queryString
as an action property for more explicit URL constructionTesting
Docs
RFC updates to be pushed on minor release