I have used decorator on React Native with typescript. I can use decorator everywhere but I can’t use as parameter decorator. For example
@Client('API_LINK')
export class Service {
@Request<any>('/profile/:id', MethodEnums.GET)
getDeneme(@UrlParam('id') id: number): any {
return null
}
}
Client and Request work but UrlParam give an error as Unhandled JS Excaption: Invalid Character ‘@’ no stack
So what can I do?