Skip to content

Conversation

@FrankFMY
Copy link
Contributor

@FrankFMY FrankFMY commented Feb 5, 2026

Summary

When submitting to a form remote function without having remote functions enabled in svelte.config.js, the error message was confusing:

POST method not allowed. No form actions exist for the page at /

This gives no indication that the user needs to enable remote functions. Now in dev mode, the error messages suggest enabling config.kit.experimental.remoteFunctions.

Before

[405] POST /
Error: POST method not allowed. No form actions exist for the page at /

After

Depending on the code path:

POST method not allowed. No form actions exist for the page at /. 
If you're trying to use remote functions, make sure they are enabled 
via `config.kit.experimental.remoteFunctions` in svelte.config.js

or for requests that reach the remote handler:

No remote functions were found. Make sure remote functions are enabled 
via `config.kit.experimental.remoteFunctions` in svelte.config.js

Changes

Improved error messages in four locations:

  • handle_action_json_request in actions.js — JSON form submission without actions
  • handle_action_request in actions.js — regular form submission without actions
  • handle_remote_form_post_internal in remote.js — remote form submission with empty remotes
  • handle_remote_call_internal in remote.js — remote function call with empty remotes

All hints are dev-mode only and don't affect production error messages.

Closes #14465

Test plan

  • All 417 unit tests pass
  • All 312 form/action integration tests pass (2 unrelated symlink failures)
  • Error messages only appear in DEV mode
  • Production error messages remain unchanged

When submitting to a form remote function without enabling remote
functions in config, the error message was confusing:
"No form actions exist for this page"

Now in dev mode, the error suggests enabling remote functions via
`config.kit.experimental.remoteFunctions` in svelte.config.js.

Closes sveltejs#14465
@changeset-bot
Copy link

changeset-bot bot commented Feb 5, 2026

🦋 Changeset detected

Latest commit: 88aeec1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@sveltejs/kit Patch

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

@svelte-docs-bot
Copy link

@dummdidumm
Copy link
Member

Closing since the related issue was closed / deemed obsolete

@dummdidumm dummdidumm closed this Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clearer error message for form actions when remote functions are not enabled

2 participants