Next.js Discord

Discord Forum

App directory runtimeConfig alternative

Unanswered
Mississippi Kite posted this in #help-forum
Open in Discord
Mississippi KiteOP
Hello I am starting to work on a migration to the app directory. We have so far used a lot of the runtimeconfig for managing flags and features that are activated in the app. The app is a single repo but which is configured independntly for clients (single tenant) and this is where the runtimeConfig comes in. We want a place where these things are commited (so a .env is not very useful for that).

What is a good alternative for this that works well with app directory. I am thinking just a config (there are no secrets in this so no sensitive information for that we use the .env) but then also client components should be able to read it so maybe making it available for them via context?

0 Replies