1.0.20 • Published 6 years ago

react-condom v1.0.20

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

React Condom

React Condom is a protective layer around your raw, unprotected components. In a claims based authentication system, a user typically has his own claims and the component can have a rule. This currently is a one to one string equality check. If the rule in a component is available within the rule set (Claims) of the user, the component renders whatever is inside, else it falls back to the fallback component.

Check the tutorial

Usage :

import ReactCondom from 'react-condom';
var ruleSet = ['rule1', 'rule2'];
var componentRule = 'rule1';
<ReactCondom ruleSet={ruleSet} rule={componentRule} fallBack={<div>Access Denied</div>}>
    <div>
        Paid Component
    </div>
<ReactCondom>
1.0.20

6 years ago

1.0.19

6 years ago

1.0.18

6 years ago

1.0.17

6 years ago

1.0.16

6 years ago

1.0.11

6 years ago

1.0.10

6 years ago

1.0.9

6 years ago

1.0.8

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago