shopping-checkout
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -11,6 +11,11 @@ 'use strict'; | ||
const packageDir = pathResolve( __dirname , '../' ); // 此 npm 包在本地系统的路径,用于定位模板位置 | ||
exports = module.exports = main; | ||
/** | ||
* 根据模板数据生成模板 | ||
* @param {Object} [options] | ||
* @param {Object} [options.cwd] - 工作目录,默认为 process.cwd() | ||
* @param {Object} [options.xlsxName='data.xlsx'] - 模板文件夹下保存模板数据的文件名 | ||
* @param {Object} [options.picturesDir='../pictures/'] - 图片文件夹位置,相对于 data.xlsx | ||
*/ | ||
function main( options ) { | ||
@@ -28,3 +33,3 @@ if ( !options ) { | ||
} else { | ||
workDir = process.cwd() | ||
workDir = process.cwd(); | ||
} | ||
@@ -68,3 +73,3 @@ | ||
fsp.copy( | ||
pathResolve( packageDir , './libs/templates/' + templateName + '/resources' ) , | ||
pathResolve( __dirname , './templates/' + templateName + '/resources' ) , | ||
pathResolve( workDir , './' + templateName + '/resources' ) | ||
@@ -71,0 +76,0 @@ ); |
{ | ||
"name": "shopping-checkout", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "根据数据生成购物网站的结算页面", | ||
@@ -5,0 +5,0 @@ "preferGlobal": true, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
233060
769