-
Hi, useFormStateMachine.ts
form.vue
All compiles and runs fine. I am using Vue-cli npm run serve. After 'submit' is pressed Machin changes state to 'submitting' and all looks fine. But after several seconds of no activity error appears - Argument of type '"SUBMIT"' is not assignable to parameter of type 'FormEvent'.
What I am doing wrong? My config: P.S Error arrives even I did not press button. In the beginning all compiles and run, and after several second - UPS - TS error. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
It was so easy to solve: I am TypeScript nub and the idea arrived too late. Anyway I hope this self-discussion will be helpful. |
Beta Was this translation helpful? Give feedback.
It was so easy to solve:
instead of
send('SUBMIT')
one should use
send({ type: 'SUBMIT' }).
I am TypeScript nub and the idea arrived too late. Anyway I hope this self-discussion will be helpful.