UNPKG

@nangazaki/vue-rbac

Version:

Role-Based Access Control (RBAC) implementation for Vue.js

12 lines (11 loc) 694 B
import type { RBACConfig, RBACState, RolesConfig } from "../types/index"; /** * Loads RBAC configuration dynamically using a user-provided resolver. * * @param state - The current RBAC state object to be updated * @param options - RBAC configuration including the resolver function * @param mergeWithExisting - When true, merges the loaded config with existing roles. When false, replaces entirely * @returns Promise resolving to the updated roles configuration * @throws Error if configuration loading fails or no valid loader is provided */ export declare function loadDynamicConfig(state: RBACState, options: Required<RBACConfig>, mergeWithExisting?: boolean): Promise<RolesConfig>;