0.0.4 • Published 3 years ago
wb-toolbox v0.0.4
wb-toolbox
javascript toolbox for wb-ui.
Installation
npm installStart Dev Server
npm startBuild Prod Version
npm run buildnpm run build-libFeatures:
- ES6 Support via babel (v7)
- JavaScript Linting via eslint
- SASS Support via sass-loader
- Autoprefixing of browserspecific CSS rules via postcss and postcss-preset-env
- Style Linting via stylelint
When you run npm run build we use the mini-css-extract-plugin to move the css to a separate file. The css file gets included in the head of the index.html.
引入
const WBToolbox = require('wb-toolbox')
import {test_reg} from 'wb-toolbox'导出方法
test_reg 数据验证
/**
* 数据验证
* @param str 待验证数据
* @param reg 使用模式[special_str(特殊字符串), idCard(身份证号)]
* @returns {*}
*/
test_reg(str, reg)