Awesome
<div align="center"> <h1>San-CLI</h1> <blockquote>A CLI Tooling based on <a href="https://baidu.github.io/san/">San.js</a> for rapid development</blockquote> <a href="https://github.com/ecomfe/san-cli/actions?query=workflow%3A%22Node.js+CI%22"> <img src="https://github.com/ecomfe/san-cli/workflows/Node.js%20CI/badge.svg"> </a> <a href="https://www.npmjs.com/package/san-cli"> <img src="http://img.shields.io/npm/v/san-cli.svg?style=flat-square" alt="NPM version"> </a> <a href="https://github.com/ecomfe/san-cli/issues"> <img src="https://img.shields.io/github/issues/ecomfe/san-cli.svg?style=flat-square" alt="Issues"> </a> <a href="https://www.npmjs.com/package/san-cli"> <img src="https://img.shields.io/github/license/ecomfe/san-cli.svg?style=flat-square" alt="License"> </a> </div>English | 简体中文
🎉 Features
- Complete project scaffolding
- webpack-based with zero configuration
- Extensible command line and webpack packaging plugins
San CLI takes into account the San ecosystem while trying to achieve universal configuration. At the beginning of the design phase, we aimed to be not limited to the San application scope, but to make a general and customizable front-end development tooling.
📦 Installation
San CLI requires Node.js version 12.13.0 or above (12.13.0+ recommended).
# use npm
npm install -g san-cli
# or use yarn
yarn global add san-cli
If you want to use San CLI only in the project, you can add it to the devDependencies of the project package.json and then use npm-scripts.
After installation, you can view the help information with the following command:
san -h
For more information, visit https://ecomfe.github.io/san-cli.
🤝 Contributing
San CLI uses Yarn Workspaces for local development.
First clone the project to your computer, then install dependencies:
# install dependencies
yarn
For design details, please read architecture.
🔨 Testing
# test all
yarn test
# or test one specific package
yarn test [packageName]
# such as
yarn test san-cli
🐛 Debug Log
The debug module is used in the San CLI, so if you need to debug or see some information you can use the DEBUG
variable. In San CLI, the scope of debug is san-cli:
, and common variables include:
perf
: Output performance log of San CLI itself.babel
: Output Babel related configuration.service
: Output service layer log.webpack:closeDevtool
: Close Devtools and no longer outputeval
type code. Directly output the packaged code for debugging.webpack:build
: Output webpack build related configuration.webpack:serve
: Output webpack serve related configuration.webpack:config
: Output the final config object of webpack.
📝 Documentation
For detailed documentation, please check the San CLI docs.
🍻 Companions
- san-devtools - Chrome DevTools extension
- san-router - SPA Router
- san-store - Application States Management
- san-update - Immutable Data Update
- san-factory - Component register and instantiation
- santd - Components Library following the Ant Design specification
- san-mui - Material Design Components Library
- san-xui - A Set of SAN UI Components that widely used on Baidu Cloud Console
- sanny - VSCode extension for SAN
- san-test-utils - The unit testing utility library for SAN
- san-loader - Webpack loader for single-file SAN components
- san-hot-loader - Webpack loader for SAN components HMR
☀️ License
MIT