chore: bump js-yml, exports

This commit is contained in:
cha0s 2022-03-01 14:27:59 -06:00
parent 0a8c66ad7d
commit 314c19a053
3 changed files with 5 additions and 3 deletions

View File

@ -64,7 +64,7 @@
"debug": "4.3.1",
"eslint": "^7.0.0",
"eslint-import-resolver-webpack": "0.13.0",
"js-yaml": "3.14.0",
"js-yaml": "4.1.0",
"jsonparse": "^1.3.1",
"lodash.flatten": "^4.4.0",
"lodash.get": "^4.4.2",

View File

@ -1,5 +1,7 @@
import {Hooks} from './flecks';
export {dump as dumpYml, load as loadYml} from 'js-yaml';
export {default as autoentry} from './bootstrap/autoentry';
export {default as fleck} from './bootstrap/fleck';
export {default as compose} from './compose';

View File

@ -114,11 +114,11 @@ export default class ServerFlecks extends Flecks {
let initial;
let configType;
try {
const {safeLoad} = R('js-yaml');
const {load} = R('js-yaml');
const filename = join(resolvedRoot, 'build', 'flecks.yml');
const buffer = readFileSync(filename, 'utf8');
debug('parsing configuration from YML...');
initial = safeLoad(buffer, {filename}) || {};
initial = load(buffer, {filename}) || {};
configType = 'YML';
}
catch (error) {