| 12345678910111213141516171819202122232425262728293031 |
- import { create } from 'zustand';
- import { SignUpFormState } from '../types/signUpFormData';
- const useSignUpStore = create<SignUpFormState>((set) => ({
- signUpFormData: {
- phone: '',
- nickName: '',
- gender: '',
- password: '',
- email: '',
- birthDate: '',
- isUberDriver: false,
- selectedCarModel: '0000',
- selectedCarBrand: '0000',
- selectedCarSeries: '0000',
- licensePlate: '0000',
- address: '',
- paymentMethod: '',
- birthDateMonth: '',
- birthDateDay: ''
- },
- setSignUpFormData: (newFormData) =>
- set((state) => ({
- signUpFormData: {
- ...state.signUpFormData,
- ...newFormData
- }
- }))
- }));
- export default useSignUpStore;
|