Skip to content

Commit

Permalink
fix(extra): add rulesToFields TS definition (#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
vonagam authored and stalniy committed Jun 30, 2019
1 parent bc76790 commit b772ad6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/casl-ability/extra/extra.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import { Ability, Rule, RawRule } from '@casl/ability'

export function rulesToQuery(ability: Ability, action: string, subject: any, convert: (rule: Rule) => Object): Object | null

export function rulesToFields(ability: Ability, action: string, subject: any): Object

export interface PermittedFieldsOptions {
fieldsFrom?: (rule: Rule) => string[] | null | undefined
}
Expand Down

0 comments on commit b772ad6

Please sign in to comment.