Skip to content

Instantly share code, notes, and snippets.

@maxp
Last active December 28, 2015 11:59
Show Gist options
  • Select an option

  • Save maxp/7497159 to your computer and use it in GitHub Desktop.

Select an option

Save maxp/7497159 to your computer and use it in GitHub Desktop.
Load json settings from current directory.
var settings = JSON.parse(
require('fs').readFileSync(
require('path').resolve(__dirname, 'settings.json'),
'utf8'
)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment