Skip to content

Commit

Permalink
Allow explicitly setting action to empty string
Browse files Browse the repository at this point in the history
  • Loading branch information
KATT authored Dec 26, 2020
1 parent 5e65ab6 commit 3128c15
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/formik/src/Form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const Form = React.forwardRef<HTMLFormElement, FormProps>(
// iOS needs an "action" attribute for nice input: https://stackoverflow.com/a/39485162/406725
// We default the action to "#" in case the preventDefault fails (just updates the URL hash)
const { action, ...rest } = props;
const _action = action || '#';
const _action = action ?? '#';
const { handleReset, handleSubmit } = useFormikContext();
return (
<form
Expand Down

0 comments on commit 3128c15

Please sign in to comment.