remote-json-loader
v1.1.1
Published
Load external JSON's with webpack
Downloads
4
Maintainers
Readme
remote json loader for webpack
Installation
npm i remote-json-loader --save-dev
Usage
// config.json
{
"app-config": "http://my-website.ninja/config.json",
"ui-config": "http://my-website.ninja/interface-config.json",
"package": "https://raw.githubusercontent.com/msn0/remote-json-loader/master/package.json",
"whatever": "https://my-website.ninja/whatever.json"
}
import pkg from 'remote-json?package!./config.json';
// or
const pkg = require('remote-json?package!./config.json');
console.log(pkg.name); // → remote-json-loader
License
MIT © Michał Jezierski