DEV Community

Discussion on: I've made a react component that hides sensitive information in your app.

Collapse
 
puritanic profile image
Darkø Tasevski

Feature flags are normally used to ignore specific parts of your code in the deployment so they wont get shipped.

You sure about that @larsonnn ?

From my experience so far, the code behind the feature flags is shipped, but is not available to the user in the production. Talking from the the frontend perspective though, not sure if in native development we can remove code behind the disabled feature flags in compile step.

Thread Thread
 
christiankozalla profile image
Christian Kozalla

We're using feature flags like in a simple if else statement. So the code is shipped and we can switch the flag on and off at runtime.

I'm sure a compile step could remove the code behind the flag, but then you couldn't toggle the flags at runtime

Thanks for sharing your experience :)