Security News
JavaScript Leaders Demand Oracle Release the JavaScript Trademark
In an open letter, JavaScript community leaders urge Oracle to give up the JavaScript trademark, arguing that it has been effectively abandoned through nonuse.
A Gulp plugin to convert Java .properties to JSON
npm install --save-dev gulp-props
const props = require('gulp-props');
// Generate a .js file with default namespace (config)
gulp.src('./src/*.properties')
.pipe(props())
.pipe(gulp.dest('./dist/'))
// Generate a .json file indented with 2 spaces
gulp.src('./src/*.properties')
.pipe(props({ namespace: '', space: 2 }))
.pipe(gulp.dest('./dist/'))
// Generate a .js file with a custom namespace (state)
gulp.src('./src/*.properties')
.pipe(props({ namespace: 'state' }))
.pipe(gulp.dest('./dist/'))
Type: String
Default: config
The namespace to use when defining properties. Javascript reserved words cannot be used here. Invalid identifiers will be adjusted to be valid, and a warning will be printed in the console.
Note: To force a JSON
output set this option to an empty string.
Type: Number
or String
Default: null
Control spacing in the resulting output. It has the same usage as for JSON.stringify
The option is used only when namespace option is an empty string.
Type: Function
or Array
Default: null
Further transform the resulting output. It has the same usage as for JSON.stringify
The option is used only when namespace option is an empty string.
Type: Boolean
Default: false
Append the extension (.js
or .json
) instead of replacing it.
Useful if the property file doesn't have an extension.
MIT © Cristian Trifan
FAQs
Convert Java .properties to JSON
The npm package gulp-props receives a total of 75 weekly downloads. As such, gulp-props popularity was classified as not popular.
We found that gulp-props demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
In an open letter, JavaScript community leaders urge Oracle to give up the JavaScript trademark, arguing that it has been effectively abandoned through nonuse.
Security News
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
Security News
Floating dependency ranges in npm can introduce instability and security risks into your project by allowing unverified or incompatible versions to be installed automatically, leading to unpredictable behavior and potential conflicts.