How to handle action matching no intent? episode artwork

EPISODE · Dec 12, 2022 · 4 MIN

How to handle action matching no intent?

from The Call Kent Podcast · host Kent C. Dodds

Hi Kent its Jan,What do you do in your action function in Remix for a page with multiple forms, if no intent matches?Let's say you have a page with two forms, one for deleting an entity and one for duplicating it. So the page has two forms each with a button of type submit, one with an intent of delete and one of with an intent of duplicate.Now what do you do if the request to that action function contains form data with neither intent?In Ryan's Remix single, where he shows how to handle multiple forms, his action is a void promise and returns nothing in the case where none of his intents match.But should you do that in a production app? Just don't do anything?Thanks for your help! And thank you for answering yesterdays question about testing tables, it helped me out tremendously.Take care!How to handle action matching no intent?

Episode metadata supplied by the publisher feed · Published Dec 12, 2022

Embed this episode

NOW PLAYING

How to handle action matching no intent?

0:00 4:25

No transcript for this episode yet

We transcribe on demand. Request one and we'll notify you when it's ready — usually under 10 minutes.

No similar episodes found.

No similar podcasts found.

Frequently Asked Questions

How long is this episode of The Call Kent Podcast?

This episode is 4 minutes long.

When was this The Call Kent Podcast episode published?

This episode was published on December 12, 2022.

Can I download this The Call Kent Podcast episode?

Yes. Use the download control on the episode player to save the publisher-provided media file.
URL copied to clipboard!