├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ ├── feature_request.md │ └── question.md ├── dependabot.yml └── workflows │ ├── build-lint-test.yml │ ├── on-pr-master.yml │ ├── on-push-master.yml │ ├── on-release.yml │ ├── publish-alpha.yml │ ├── publish-coverage.yml │ └── publish-with-git-tag-version.yml ├── .gitignore ├── .mergify.yml ├── .prettierrc ├── .vscode └── settings.json ├── LICENSE ├── README.md ├── __tests__ ├── index.spec.ts └── utils │ ├── create-test.ts │ ├── fastify-extra-wait.ts │ ├── platforms.ts │ └── request-with-role.ts ├── eslint.config.cjs ├── jest.config.js ├── package.json ├── src ├── check-roles.ts ├── index.ts ├── role-reflection-token.ts └── roles-guard-static.ts ├── tsconfig.build.json └── tsconfig.json /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/ISSUE_TEMPLATE/bug_report.md -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/ISSUE_TEMPLATE/feature_request.md -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/question.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/ISSUE_TEMPLATE/question.md -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/dependabot.yml -------------------------------------------------------------------------------- /.github/workflows/build-lint-test.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/build-lint-test.yml -------------------------------------------------------------------------------- /.github/workflows/on-pr-master.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/on-pr-master.yml -------------------------------------------------------------------------------- /.github/workflows/on-push-master.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/on-push-master.yml -------------------------------------------------------------------------------- /.github/workflows/on-release.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/on-release.yml -------------------------------------------------------------------------------- /.github/workflows/publish-alpha.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/publish-alpha.yml -------------------------------------------------------------------------------- /.github/workflows/publish-coverage.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/publish-coverage.yml -------------------------------------------------------------------------------- /.github/workflows/publish-with-git-tag-version.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.github/workflows/publish-with-git-tag-version.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.gitignore -------------------------------------------------------------------------------- /.mergify.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.mergify.yml -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.prettierrc -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/.vscode/settings.json -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/README.md -------------------------------------------------------------------------------- /__tests__/index.spec.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/__tests__/index.spec.ts -------------------------------------------------------------------------------- /__tests__/utils/create-test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/__tests__/utils/create-test.ts -------------------------------------------------------------------------------- /__tests__/utils/fastify-extra-wait.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/__tests__/utils/fastify-extra-wait.ts -------------------------------------------------------------------------------- /__tests__/utils/platforms.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/__tests__/utils/platforms.ts -------------------------------------------------------------------------------- /__tests__/utils/request-with-role.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/__tests__/utils/request-with-role.ts -------------------------------------------------------------------------------- /eslint.config.cjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/eslint.config.cjs -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/jest.config.js -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/package.json -------------------------------------------------------------------------------- /src/check-roles.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/src/check-roles.ts -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/role-reflection-token.ts: -------------------------------------------------------------------------------- 1 | export const roleReflectionToken = 'nestjs-roles'; 2 | -------------------------------------------------------------------------------- /src/roles-guard-static.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/src/roles-guard-static.ts -------------------------------------------------------------------------------- /tsconfig.build.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/tsconfig.build.json -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamolegga/nestjs-roles/HEAD/tsconfig.json --------------------------------------------------------------------------------