扫一扫分享
strman一个针对 Javascript 字符串的操作库,包含各种各样的字符串操作
npm/yarn安装
npm install strman --save
yarn add strman
strman使用
//With ES6/import
import { slugify } from 'strman'
const title = "A Javascript string manipulation library.";
slugify(title);
// => "a-javascript-string-manipulation-library"
//With require
const slugify = require('strman').slugify;
const title = 'A Javascript string manipulation library.'
slugify(title)
// => "a-javascript-string-manipulation-library"
手机预览