Security News
New Python Packaging Proposal Aims to Solve Phantom Dependency Problem with SBOMs
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
confab-features
Advanced tools
Feature gates for confab. Declare a list of features that can be toggled on and off:
var confab = require('confab');
var features = require('confab-features');
var config = confab([
features([
'new_ui'
])
]);
Run the app with gates set by either a previous transformation or environment overrides:
$ CONFIG_FEATURES_NEW_UI=true \
node app.js
Then, inside the app, retrieve the feature configurations from a processed
confab config
:
if (config.features.new_ui) {
renderNewUi();
}
else {
renderLegacyUi();
}
The full list of configured features is available by invoking config.features
directly:
config.features().forEach(function (feature) {
console.log(feature.key, feature.description);
});
confab-features
exports:
features(items: Array<Object|String>, opts: Map<String, any>): Map<String, Boolean>
Note that items
may contain both string keys
and simple object with a key
and (optional) description of the feature:
[
'new_ui',
{ key: 'new_campaign', description: 'A switch to flip' }
]
Name | Type | Description |
---|---|---|
configKey | String | The config key for 'features' and environment variables (default: 'features' ) |
validate | Boolean | Throw on undeclared or invalid feature settings (default: true ) |
Quis configiet ipsos configes?
Clone this repository:
$ git clone git@github.com:rjz/confab-features.git
...and copy, fork, customize, and whatever you need to do.
Lint and run test suite:
$ npm test
MIT
FAQs
Runtime feature gating for confab applications
The npm package confab-features receives a total of 3 weekly downloads. As such, confab-features popularity was classified as not popular.
We found that confab-features 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
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
Security News
Socket CEO Feross Aboukhadijeh discusses open source security challenges, including zero-day attacks and supply chain risks, on the Cyber Security Council podcast.
Security News
Research
Socket researchers uncover how threat actors weaponize Out-of-Band Application Security Testing (OAST) techniques across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.