You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In handlers.ts, when I instantiate a Task object without one of the required properties, no error is thrown at compile time. Error is thrown at runtime. Also, intellisense of VS Code does not work with the property names. Is that expected behaviour? I expected class-like autocomplete behaviour. Is it possible to add a constructor to instantiate new objects of type Task, in my case?
The text was updated successfully, but these errors were encountered:
The code:
The main file:
server.ts
A sample schema:
schema/task.ts
Models:
models.ts
Routes file (WIP):
route.ts
Handlers file (WIP):
handlers.ts
In
handlers.ts
, when I instantiate a Task object without one of the required properties, no error is thrown at compile time. Error is thrown at runtime. Also, intellisense of VS Code does not work with the property names. Is that expected behaviour? I expected class-like autocomplete behaviour. Is it possible to add a constructor to instantiate new objects of type Task, in my case?The text was updated successfully, but these errors were encountered: