UNPKG

@casl/react

Version:

React component for CASL which makes it easy to add permissions in any React application

65 lines (64 loc) 1.86 kB
{ "name": "@casl/react", "version": "5.0.0", "description": "React component for CASL which makes it easy to add permissions in any React application", "main": "dist/umd/index.js", "module": "dist/es5m/index.js", "es2015": "dist/es6m/index.mjs", "typings": "./index.d.ts", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es6m/index.mjs", "require": "./dist/umd/index.js" } }, "repository": { "type": "git", "url": "https://github.com/stalniy/casl.git", "directory": "packages/casl-react" }, "homepage": "https://casl.js.org", "publishConfig": { "access": "public" }, "scripts": { "build.prepare": "rm -rf dist/* && npm run build.types", "build": "npm run build.prepare && BUILD_TYPES=es5m,es6m,umd dx rollup -n casl.react -g react:React,prop-types:React.PropTypes,@casl/ability:casl", "build.types": "dx tsc", "lint": "dx eslint src/ spec/", "test": "dx jest --env jsdom", "release.prepare": "npm run lint && npm test && NODE_ENV=production npm run build", "release": "npm run release.prepare && dx semantic-release" }, "keywords": [ "casl", "react", "authorization", "acl", "permissions" ], "author": "Sergii Stotskyi <sergiy.stotskiy@gmail.com>", "license": "MIT", "peerDependencies": { "@casl/ability": "^4.0.0 || ^5.1.0 || ^6.0.0", "react": "^17.0.0 || ^18.0.0 || ^19.0.0" }, "devDependencies": { "@casl/ability": "^6.0.0", "@casl/dx": "workspace:^1.0.0", "@testing-library/dom": "^10.4.0", "@testing-library/react": "^16.1.0", "@types/jest": "^29.0.0", "@types/node": "^22.0.0", "@types/react": "^19.0.0", "chai": "^4.1.0", "chai-spies": "^1.0.0", "react": "^19.0.0", "react-dom": "^19.0.0" }, "files": [ "dist", "*.d.ts" ] }