Created
July 6, 2020 19:59
-
-
Save nmchenry01/e23a810cc09030849e0d2bc2c8cf579c to your computer and use it in GitHub Desktop.
Task Controller V1 for "Why you should use NestJS for your next project" Blog
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Controller, Get, Post } from '@nestjs/common'; | |
@Controller('task') | |
export class TaskController { | |
@Post() | |
createTask(): string { | |
return 'This action adds a new task'; | |
} | |
@Get() | |
findAllTasks(): string { | |
return 'This action returns all tasks'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment