Comments (5)
What I mean is the nested objects. Not the computed flags.
from flagged.
Hi @r-inaldi
I have no plans to add more complex flags object, so far I haven't need it and reading the example I'm not sure it's a good practice, aside of helping organizing similar flags.
However I could make it easy for you to add that support yourself, I'm planning adding a useFeatures
hook which will return the whole features object/array so you could make a custom useFeature
, Feature
or withFeature
with support for nested objects.
from flagged.
It was easier than I think to add nested flags support and to open useFeatures for external usage I still needed to add type support for nested flags so I directly added it.
from flagged.
It's published in v1.1.0
from flagged.
Thanks @sergiodxa 👍
from flagged.
Related Issues (12)
- <Feature> Component support camelCase names? HOT 1
- Is the package transpiled? HOT 2
- Provider chaining support HOT 4
- How to get the list of features on a Class Component? HOT 1
- Display a fallback when the feature is not enabled HOT 5
- Validate multiple feature names at once HOT 4
- Request to support feature disabled for Wrapper Component Feature HOT 1
- Undefined variable warning
- Error: Invalid hook call. Hooks can only be called inside of the body of a function component. HOT 3
- Example from README gives TypeScript error HOT 1
- Error when using `useFeature` hook and feature is not defined
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flagged.