a transform for loading Java .properties files in RequireJS, using java.properties.js
Install the plugin and its dependencies using bower
$ bower install java.properties.js --save
If you prefer a manual install, make sure to satisfy the
First, make sure the module names
text resolve to the proper locations:
Now you're ready to
NOTE: In contrast to the default java.properties.js behaviour keys with dots in them will not result in nested objects. So a properties key like:
Will result in this JSON object:
"key": 12"key.with.dots": "foobar"
This is due to the specific requirements for which this plugin was build.
On build time you can simply use
stubModules in your build config to get rid of the parser in the file you ship to production:
stubModules: 'text' 'java.properties' 'properties'
This plugin is a based upon require-yaml.