@bem/sdk.config — options.extendBy
const config = require('@bem/sdk.config');
const mockfs = require('mock-fs');
const { stripIndent } = require('common-tags');
const bemConfig = config({
extendBy: {
levels: [
{ path: 'path/to/level', test: 1 }
],
common: 'overriden',
extended: 'yo'
}
});
mockfs({
'.bemrc': stripIndent`
module.exports = {
'root': true,
'levels': {
'common.blocks': {},
'desktop.blocks': {}
},
'modules': {
'bem-tools': {
'plugins': {}
}
}
}`
});
const conf = await bemConfig.get();
conf;
no comments