@eggjs/utils
Version:
Utils for all egg projects
59 lines (39 loc) • 1.89 kB
Markdown
# @eggjs/utils
[![NPM version][npm-image]][npm-url]
[](https://github.com/eggjs/utils/actions/workflows/nodejs.yml)
[![Test coverage][codecov-image]][codecov-url]
[![npm download][download-image]][download-url]
[](https://nodejs.org/en/download/)
[](https://makeapullrequest.com)
[npm-image]: https://img.shields.io/npm/v/@eggjs/utils.svg?style=flat-square
[npm-url]: https://npmjs.org/package/@eggjs/utils
[codecov-image]: https://codecov.io/github/eggjs/utils/coverage.svg?branch=master
[codecov-url]: https://codecov.io/github/eggjs/utils?branch=master
[download-image]: https://img.shields.io/npm/dm/@eggjs/utils.svg?style=flat-square
[download-url]: https://npmjs.org/package/@eggjs/utils
Utils for all egg projects.
## Installation
```bash
npm i @eggjs/utils
```
## API
### `getPlugins(options)`
- {String} baseDir - the current directory of application
- {String} framework - the directory of framework
- {String} env - egg environment
### `getLoadUnits(options)`
- {String} baseDir - the current directory of application
- {String} framework - the directory of framework
- {String} env - egg environment
### `getConfig(options)`
- {String} baseDir - the current directory of application
- {String} framework - the directory of framework
- {String} env - egg environment
### `getFrameworkPath(options)`
- {String} baseDir - the current directory of application
- {String} framework - the directory of framework
## License
[MIT](LICENSE)
## Contributors
[](https://github.com/eggjs/utils/graphs/contributors)
Made with [contributors-img](https://contrib.rocks).