MCPcopy Create free account
hub / github.com/RosyTucker/react-feature-toggles / ExampleComponent

Function ExampleComponent

example/example.jsx:16–28  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

14};
15
16const ExampleComponent = () => (
17 <FeatureToggleProvider featureToggleList={toggles}>
18 <div>
19 <h1>Toggling Example</h1>
20 <FeatureToggle featureName={toggleNames.SHOW_HELLO_WORLD}>
21 <p>Hello World</p>
22 </FeatureToggle>
23 <FeatureToggle featureName={toggleNames.SHOW_HELLO_WORLD} showOnlyWhenDisabled>
24 <p>Sorry, toggle is off</p>
25 </FeatureToggle>
26 </div>
27 </FeatureToggleProvider>
28);
29
30
31ReactDOM.render(<ExampleComponent />, document.getElementById('example'));

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected