1.0.2 • Published 2 years ago
generator-diy-test v1.0.2
安装
npm install -g generator-diy-test
功能
根据 ejs 模板文件,用于自动化创建文件
使用方法
- 首先安装所需 npm 包
npm i -g yo
npm i -g generator-diy-test
- 接下来可以使用命令行工具
yo diy-test
PS D:\test> npx yo diy-test
? Your Project name is testNpm
create template.xhtml
No change to package.json was detected. No package manager install will be executed.
将会产生一个文件如下:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>testNpm</title>
</head>
<body>
这是一个title为testNpm的网页!!!
</body>
</html>