1
0
mirror of https://github.com/locomotivemtl/locomotive-boilerplate.git synced 2026-01-15 00:55:08 +08:00

Add build config dynamic import assertation type

This commit is contained in:
Deven Caron
2023-02-02 10:00:20 -05:00
parent e4ae03a94c
commit 7c1b61eda9

View File

@@ -2,17 +2,19 @@
* @file Provides simple user configuration options.
*/
import loconfig from '../../loconfig.json' assert { type: "json" };
import loconfig from '../../loconfig.json' assert { type: 'json' };
let usrconfig;
try {
usrconfig = await import('../../loconfig.local.json');
usrconfig = await import('../../loconfig.local.json', {
assert: { type: 'json' }
});
usrconfig = usrconfig.default;
merge(loconfig, usrconfig);
} catch (err) {
// do nothing
console.error(err);
}
export default loconfig;