@benmvp/cli
v7.0.0
Published
A highly-opinionated, zero-config CLI for consistent infra for Ben Ilegbodu's Typescript-based libraries
Downloads
43
Readme
@benmvp/cli
A highly-opinionated, zero-config CLI for consistent infra for Ben Ilegbodu's Typescript-based libraries.
ToC
- Installation
- Quick Usage
- Docs
- Supported Node Versions
- Technologies Used
- Contributing
- Project philosophy
- License
Installation
npx @benmvp/cli create my-awesome-lib
Installs the latest version of @benmvp/cli
as a dev dependency and updates the package.json
as follows:
{
"name": "my-awesome-lib",
"scripts": {
"start": "benmvp start",
"test": "benmvp test",
"build": "benmvp build"
}
}
Read the API docs for more on benmvp create
.
Quick Usage
Unit Testing
npm test
In your continuous integration (CI) environment, run npm test
(or yarn test
) to do a one-time pass of Typescript typings, ESLint linting, and Jest unit tests. This can also be run locally (i.e. for commit hooks).
Read the API docs for more on benmvp test
.
Developing
npm start
When developing, run npm start
(or yarn start
) which will validate Typescript typings, ESLint linting, and Jest unit tests as you develop and change code.
Read the API docs for more on benmvp start
.
Building
npm run build
In your continuous integration (CI) environment, run npm run build
(or yarn build
) to generate transpiled versions of your code in ESM (ECMAScript module) and CJS (CommonJS), as well as TypeScript definition files.
Read the API docs for more on benmvp build
.
Integration Testing
npm run integrate
In your continuous integration (CI) environment, run npm run integrate
(or yarn integrate
) to run additional integration tests for the library. The integration "project" will also be typed and linted. This can also be run locally (i.e. for commit hooks but is not recommended).
Read the API docs for more on benmvp integrate
.
Docs
@benmvp/cli
has two interfaces: a CLI and a Node API. View the full docs.
Supported Node Versions
The CLI has been tested to work in Node 8+.
Technologies Used
- TypeScript (type-checking)
- Babel (transpiling)
- Jest (testing & code coverage)
- React testing library (testing React components)
- ESLint (linting)
- Prettier (code formatting)
- Yargs (command line argument parsing)
Contributing
Contributions are welcome! See Contributing Guidelines for more details.
Project philosophy
We take the stability of this SDK very seriously. @benmvp/cli
follows the SemVer standard for versioning.
All updates must pass the CI build.
License
The library is available as open source under the terms of the MIT License.