Refactor routing in App component to enhance navigation and improve error handling by integrating dynamic routes and updating the NotFound route.
This commit is contained in:
11
node_modules/load-yaml-file/index.js
generated
vendored
Normal file
11
node_modules/load-yaml-file/index.js
generated
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
'use strict'
|
||||
|
||||
const fs = require('graceful-fs')
|
||||
const pify = require('pify')
|
||||
const stripBom = require('strip-bom')
|
||||
const yaml = require('js-yaml')
|
||||
|
||||
const parse = data => yaml.safeLoad(stripBom(data))
|
||||
|
||||
module.exports = fp => pify(fs.readFile)(fp, 'utf8').then(data => parse(data))
|
||||
module.exports.sync = fp => parse(fs.readFileSync(fp, 'utf8'))
|
Reference in New Issue
Block a user