0
var url = 'assets/json/data.json' //this url changes based on the environment

function() {
const data = require(url);
console.log(data);
}

I am unable to read the json data. It throws the error saying 'app.exceptions.ts:34 Error: Uncaught (in promise): Error: Cannot find module'

Please help.

4

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.