diff --git a/package.json b/package.json index 71fd179..b5d3967 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "remix-hook-form", - "version": "1.1.0", + "version": "1.1.1", "description": "Utility wrapper around react-hook-form for use with Remix.run", "type": "module", "main": "./dist/index.umd.cjs", diff --git a/src/hook/index.tsx b/src/hook/index.tsx index c0d78d6..1b22efd 100644 --- a/src/hook/index.tsx +++ b/src/hook/index.tsx @@ -70,7 +70,7 @@ export const useRemixForm = ({ submitHandlers?.onValid ?? onSubmit, submitHandlers?.onInvalid ?? onInvalid ), - register: (name: Path, options: RegisterOptions) => ({ + register: (name: Path, options?: RegisterOptions) => ({ ...methods.register(name, options), defaultValue: data?.defaultValues?.[name] ?? "", }),