enhanced-properties-loader

NPM version Travis build status AppVeyor build status Code Climate Maintainability Code Climate Coverage Dependency Status Development Dependency Status Greenkeeper badge

enhanced-properties-loader

*.properties loader for webpack

Installation

npm install json-loader enhanced-properties-loader --save-dev

or

yarn add json-loader enhanced-properties-loader --dev

Usage

./index.properties

foo=bar
bar.baz=qux

./index.js

var properties = require('!json!enhanced-properties!./index.properties');

console.log(properties); // Object { foo: "bar", bar: { baz: "qux" } }

./webpack.config.js

module.exports = {
    module: {
        rules: [{
            test: /\.properties$/,
            loader: 'enhanced-properties-loader'
        }]
    }
};