I'm at the very beggining of NestJS course. Insomnia and localhost seem to work well. On @Get request there is no problem to return a simple message, but for example in @Patch or @Delete decorator, when the tutorial says to return lorem ipsum #${id}
where ${id} should be localhost:3000/coffes/726 and just return "lorem ipsum 726" it returns it not finding the variable.
return "lorem ipsum #${id}"
returns return "lorem ipsum #${id} instead of return "lorem ipsum 726
CodePudding user response:
I think you should return this message, because the id isn't parsed in your expression :
return `this action updates ${id}`
check out the documentation for more informations