I am using rollup and I have a js project set up like this:
- public
- src
+ components
main.js
manifest.json
rollup.config.js
package.json
etc...
Standard setup. In src/components/app/app.js I would like to have access to the values in manifest.json - they are part of the project configuration. How can I achieve this?
Edit: It would be super nice to be able to do for example in app.js:
import config from 'config';
const routes = config.routes;
import config from '../../../manifest.json';should work according to app.js path you provided. Are you getting any error ?var config = require('../../../manifest.json');is another option :D