JSON Plugin

Description

Allows .json files to be imported as javascript objects

Usage

Setup

Import from FuseBox

const {JSONPlugin} = require("fuse-box");

Inject into a chain

fuse.plugin(
     JSONPlugin()
)

Or add it to the main config plugins list to make it available across bundles

FuseBox.init({
    plugins : [
         JSONPlugin()
    ]
});

Require file in your code

import * as config from "./config.json"

Options

None.

Test

To run tests

node test --file=JSONPlugin.test.ts