feat: refactor subscription handling in registration form and header component
This commit is contained in:
@@ -31,6 +31,7 @@ export const FormRegister = () => {
|
||||
const [disabled, setDisabled] = useState(false)
|
||||
const fetcher = useFetcher()
|
||||
const loaderData = useRouteLoaderData<typeof loader>('routes/_layout')
|
||||
const subscriptions = loaderData?.subscriptionsData
|
||||
|
||||
const formMethods = useRemixForm<TRegisterSchema>({
|
||||
mode: 'onSubmit',
|
||||
@@ -98,7 +99,7 @@ export const FormRegister = () => {
|
||||
name="subscribe_plan"
|
||||
label="Subscription"
|
||||
placeholder="Pilih Subscription"
|
||||
options={loaderData?.subscriptionsData}
|
||||
options={subscriptions}
|
||||
/>
|
||||
|
||||
{error && (
|
||||
|
||||
Reference in New Issue
Block a user