Skip to content

Instantly share code, notes, and snippets.

@arqex
Created April 15, 2018 11:27
Show Gist options
  • Save arqex/32f0771b780a4636131d507f5ea1b816 to your computer and use it in GitHub Desktop.
Save arqex/32f0771b780a4636131d507f5ea1b816 to your computer and use it in GitHub Desktop.
Config using NODE_ENV
const config = {}
if( process.env.NODE_ENV === 'production' ){
config.remoteURL = 'http://myserver.com/resource';
}
else {
config.remoteURL = 'http://localhost/resource';
}
export default config;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment