Repository URL to install this package:
|
Version:
1.1.17 ▾
|
import { isObj, EMPTY_OBJ, EMPTY_ARRAY } from 'exotic'
const config = new Map()
const setConfig = x => {
Object.keys(x).forEach(key => config.set(key, x[key]))
const pathParams = config.get('pathParams')
const routePathsList = isObj(pathParams)
? Object.values(pathParams)
: EMPTY_ARRAY
config.set('routePathsList', routePathsList)
}
setConfig({
pathParams: {},
routes: [],
})
export { config, setConfig }