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
Describe the bug
Not sure if this is a bug or intended.
The body function and other parameter functions aren't actually functions that typescript can build.
Other decorators seem to be fine and actually build and resolve to a value e.g. class decorators and method decorators.
To Reproduce
Steps to reproduce the behavior:
npx @airtasker/spot init
npx tsx ./api.ts
Console error TypeError: decorator is not a function (it seems to error on the first instance of use of the @body decorator).
This error also appears while using SWC, I haven't tired TSC.
Expected behavior
I would expect that typescript would be able to build the solution but it seems it cant.
The @body and other method parameter decorators don't resolve to a real value, they are "undefined"
Actual building of API docs works fine via npx @airtasker/spot generate --contract api.ts
Screenshots
Desktop (please complete the following information):
OS: Macbbok M1 Pro 14.1 (23B74)
Yarn version v1.22.19
v18.18.2
Spot version: 1.12.0
Additional context
Please respond with if this is expected behaviour or a bug with how I'm using the library.
The text was updated successfully, but these errors were encountered:
Describe the bug
Not sure if this is a bug or intended.
The body function and other parameter functions aren't actually functions that typescript can build.
Other decorators seem to be fine and actually build and resolve to a value e.g. class decorators and method decorators.
To Reproduce
Steps to reproduce the behavior:
npx @airtasker/spot init
npx tsx ./api.ts
TypeError: decorator is not a function
(it seems to error on the first instance of use of the@body
decorator).This error also appears while using SWC, I haven't tired TSC.
Expected behavior
I would expect that typescript would be able to build the solution but it seems it cant.
The
@body
and other method parameter decorators don't resolve to a real value, they are "undefined"Actual building of API docs works fine via
npx @airtasker/spot generate --contract api.ts
Screenshots
Desktop (please complete the following information):
Additional context
Please respond with if this is expected behaviour or a bug with how I'm using the library.
The text was updated successfully, but these errors were encountered: