Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
maybe-config
Advanced tools
A safe object traversal method, used for easy configuration grabbing.
maybe-config is a package designed to safely traverse configuration objects, allowing deep trawling without fear of errors from incorrect keys, undefineds, and all the goodness that usually comes out of working with Javascript.
maybe-config uses the concept of the Maybe monad to allow for safe traversal. The final usage for interface by default provides plain values, but also provides Safe variants that instead return the Maybe instance for further safe processing.
// my-config.js
// Create a passthrough module that will set the context for your Config object
const Config = require('maybe-config');
module.exports = Config(window.myConfig);
// Import your passthrough module to have a ready to use config object
const Config = require('./my-config');
// Grab a single value from the root.
const setting1 = Config.get('setting1');
// Grab a value from a path
const setting2 = Config.getIn('setting1', 'setting2');
// (client specific) grab a value starting at the 'settings' root key.
const clientSetting = Config.getClientSetting('clientSetting');
// Get a flag from the 'flags' root key as a bool.
const hasHeader = Config.getFlag('hasHeader');
// simply add Safe to the end of any method name to get a Maybe instance
const clientNameUpper = Config.getSafe('name').map(name => name.toUpperCase()).value();
FAQs
A safe object traversal method, used for easy configuration grabbing.
The npm package maybe-config receives a total of 0 weekly downloads. As such, maybe-config popularity was classified as not popular.
We found that maybe-config 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
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.