Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
bem-config
Advanced tools
var bemConfig = require('bem-config');
var optionalConfig = { plugins: { create: { techs: ['styl', 'browser.js'] } } };
var projectConfig = bemConfig(options); // returns promise
All options are optional:
name
// 'bem'projectRoot
// process.cwd()config
// extends found configs with this objectargv
// custom path to config on FS via command line argument --config
(defaults to null
)var config = require('bem-config')();
config.get().then(function(conf) {
console.log(conf); // config is a merge of CLI args + optionalConfig + all configs found by rc
});
var config = require('bem-config')();
config.level('path/to/level').then(function(levelConf) {
console.log(levelConf); // merged level config
});
var config = require('bem-config')();
config.library('bem-components').then(function(libConf) {
console.log(libConf); // library config
});
var config = require('bem-config')();
config.levelMap().then(function(levelMap) {
console.log(levelMap); // all levels hash with their options
});
var config = require('bem-config')();
config.module('bem-tools').then(function(bemToolsConf) {
console.log(bemToolsConf); // merged config for required module
});
var config = require('bem-config')();
config.configs().then(function(configs) {
console.log(configs); // all found configs from all dirs
});
{
"root": true,
"levels": {
"path/to/level": {
"scheme": "nested"
}
},
"libs": {
"libName": {
"path": "path/to/lib"
}
},
"sets": {
"setName": ["level1", "level2"]
},
"modules": {
"bem-tools": {
"plugins": {
"create": {
"techs": [
"css", "js"
],
"templateFolder": "/Users/tadatuta/Sites/bem/bem-tools-create/templates",
"templates": {
"js-ymodules": "/Users/tadatuta/Sites/bem/bem-tools-create/templates/js"
},
"techsTemplates": {
"js": "js-ymodules"
},
"levels": {
"path/to/level": {
"techs": ["bemhtml.js", "trololo.olo"]
}
}
}
}
},
"bem-libs-site-data": {
"someOption": "someValue"
}
}
}
levels
override common options.
FAQs
Config module for bem-tools
The npm package bem-config receives a total of 60 weekly downloads. As such, bem-config popularity was classified as not popular.
We found that bem-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
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.