Inlined FS constants without the FS module dependency.
npm install filesystem-constantsAlso provides a few utility functions for converting fs.open flags between OSX and Linux, and for converting between string and integer representations.
npm i filesystem-constants --savefs.constants.fs.constants.``js`
const { linux, parse } = require('filesystem-constants')
const flags = parse(linux, 'w+') // 578
`js``
const { linux, darwin, translate } = require('filesystem-constants')
translate(darwin, linux, darwin.O_CREATE | darwin.O_APPEND) // 1088 (linux.O_CREATE | linux.O_APPEND)