isAccessible
API / publicodes / utils / isAccessible
function isAccessible(
rules,
contextName,
name): boolean
Experimental
Check wether a rule is accessible from a namespace.
Takes into account that some namespace can be private
, i.e. that they can only be
accessed by immediate parent, children or siblings.
Parameters
Parameter | Type | Description |
---|---|---|
rules | ParsedRules | The parsed rules |
contextName | string | The context of the call |
name | string | The namespace checked for accessibility |
Returns
boolean