Skip to content

Instantly share code, notes, and snippets.

@ojhaujjwal
Last active June 10, 2020 13:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ojhaujjwal/e03986f6cf21982f2d9d952e8536eaaf to your computer and use it in GitHub Desktop.
Save ojhaujjwal/e03986f6cf21982f2d9d952e8536eaaf to your computer and use it in GitHub Desktop.
import { Controller, Get } from '@nestjs/common';
import { AdminController, AccessControlGuard } from 'app/decorators';
@AdminController({ path: '/dashboard' })
export class AdminDashboardController {
@Get()
index(): string {
return 'dashboard data for admin';
}
}
@AdminController({ path: '/posts' })
export class AdminPostsController {
@Get()
findPaginated(): string {
return 'all posts for the page';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment