Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Robsahm authored Dec 1, 2016
1 parent 6d31a8a commit 074489a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ Create the following enviroment variables

Initiate config fetching. `environment` is one of "dev", "stage" or "prod"
```
var refreshConfig = require("next-config-client");
refreshConfig(enviroment);
var configClient = require("next-config-client");
configClient.initializeConfigUpdate(enviroment)
.then((config) => {
// Do stuff with config and start app
});
```
Later use `configClient.getConfig()` to get the latest config

0 comments on commit 074489a

Please sign in to comment.