Comparing version 0.1.0 to 0.1.1
@@ -54,2 +54,10 @@ module.exports = function(grunt) { | ||
basePathTest: { | ||
src: ['tests/fixtures/**/*.eco'], | ||
dest: 'tmp/basePathTest/all.js', | ||
options: { | ||
basePath: 'tests/fixtures' | ||
} | ||
}, | ||
amdTest: { | ||
@@ -56,0 +64,0 @@ options: { |
@@ -7,3 +7,3 @@ { | ||
], | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"licenses": [ | ||
@@ -10,0 +10,0 @@ { |
@@ -37,2 +37,8 @@ # grunt-eco | ||
#### basePath | ||
Type: `String` | ||
Default: `empty` | ||
Defines substing which gets removed from JSTpath of output template. | ||
### emptyWarning | ||
@@ -39,0 +45,0 @@ |
@@ -20,2 +20,7 @@ /* | ||
if (options.basePath) { | ||
var re = new RegExp(options.basePath + '\/?'); // match basePath + optional path separator | ||
JSTpath = JSTpath.replace(re, ''); | ||
} | ||
if (input.length < 1) { | ||
@@ -36,2 +41,3 @@ if (options.emptyWarning) { | ||
if (options.amd) { | ||
@@ -57,2 +63,3 @@ output = 'define(function(){\n' + | ||
amd: false, | ||
basePath: '', | ||
emptyWarning: true, | ||
@@ -62,6 +69,2 @@ jstGlobalCheck: true | ||
if (options.basePath) { | ||
grunt.fail.warn('basePath is no longer supported. please refer to README.'); | ||
} | ||
this.files.forEach(function(file) { | ||
@@ -68,0 +71,0 @@ var destFile = path.normalize(file.dest); |
@@ -82,2 +82,16 @@ var grunt = require('grunt'), | ||
basePathTest: function(test) { | ||
'use strict'; | ||
test.expect(1); | ||
assertFileEquality(test, | ||
'tmp/basePathTest/all.js', | ||
'tests/expected/basePathTest/all.js', | ||
'Should compile all templates into one file'); | ||
test.done(); | ||
}, | ||
amdTest: function(test) { | ||
@@ -84,0 +98,0 @@ 'use strict'; |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
42215
22
1222
140
0