https://github.com/stalniy/casl-persisted-permissions-example
This example shows how to configure CASL with permissions that is stored in the database
https://github.com/stalniy/casl-persisted-permissions-example
acl casl example permissions roles
Last synced: about 1 month ago
JSON representation
This example shows how to configure CASL with permissions that is stored in the database
- Host: GitHub
- URL: https://github.com/stalniy/casl-persisted-permissions-example
- Owner: stalniy
- License: mit
- Created: 2020-04-01T14:16:24.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-03-26T10:40:35.000Z (over 3 years ago)
- Last Synced: 2025-08-22T11:50:39.693Z (about 2 months ago)
- Topics: acl, casl, example, permissions, roles
- Language: TypeScript
- Size: 283 KB
- Stars: 11
- Watchers: 2
- Forks: 3
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# CASL roles with persisted permissions
This example shows how to configure [CASL](https://github.com/stalniy/casl) with permissions that is stored in the database. See [Cookbook](https://stalniy.github.io/casl/en/cookbook/roles-with-persisted-permissions) for details.
## Installation
```sh
npm ci
npm run migrate # migrates sqlite database
npm run seed # adds default records to the database
```## Run
To run application:
```sh
npm start
```To update permissions of a member role:
```sh
npm run allowMembersToCreateAnyArticle
```