npm.io
1.4.0 • Published 3 years ago

load-yml

Licence
MIT
Version
1.4.0
Deps
3
Size
12 kB
Vulns
0
Weekly
0
Stars
3

load-yml

Read and parse a .yaml or .yml file

NPM version Codacy Badge tree shaking typescript Test coverage npm download License

Sonar

Installing

# use pnpm
$ pnpm install load-yml

# use npm
$ npm install load-yml --save

# use yarn
$ yarn add load-yml

Usage

  1. use load-yml in async mode
import { loadYml } from 'load-yml'

loadYml().then(path => {
  console.log('result is: ', path) // { "name": "saqqdy" }
})
  1. use load-yml in sync mode
import { loadYmlSync } from 'load-yml'

console.log('result is: ', loadYmlSync()) // { "name": "saqqdy" }

Support & Issues

Please open an issue here.

License

MIT

Keywords