iya-sts
    Preparing search index...
    applyEdit: (
        policy: any,
        path: string,
        action: string,
        params?: EditParams,
    ) => EditResult = ...

    Type Declaration

      • (policy: any, path: string, action: string, params?: EditParams): EditResult
      • Applies one edit to a policy model, in place.

        Every node it adds is complete and valid on its own. An Effect that is neither Permit nor Deny is refused.

        Parameters

        • policy: any

          the policy model, mutated

        • path: string

          the dotted path the edit applies at

        • action: string

          the edit, one of the grammar's actions

        • Optionalparams: EditParams

          the edit's form fields

        Returns EditResult

        { ok: true, what }, or { ok: false, why } when the path no longer resolves or the edit is refused