Skip to content

Instantly share code, notes, and snippets.

@lekhnath
Created June 15, 2017 07:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lekhnath/303ba20f4c66315fab5ce8616a35ca00 to your computer and use it in GitHub Desktop.
Save lekhnath/303ba20f4c66315fab5ce8616a35ca00 to your computer and use it in GitHub Desktop.
Cannot import / require json files in javascript projects with checkJs enabled
{
"name": "Lekhnath Rijal"
}
const config = require('./config.json');
{
"compilerOptions": {
"checkJs": true,
"module": "commonjs",
"baseUrl": "./",
"target": "es5",
"lib": [
"es6"
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment