Compare commits
3 commits
b07c088ab7
...
aa2a84860e
Author | SHA1 | Date | |
---|---|---|---|
aa2a84860e | |||
55f2d5cc14 | |||
f3382488fe |
3 changed files with 5 additions and 5 deletions
4
package-lock.json
generated
4
package-lock.json
generated
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "@flashwave/assproc",
|
||||
"version": "0.12.0",
|
||||
"version": "0.14.0",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@flashwave/assproc",
|
||||
"version": "0.12.0",
|
||||
"version": "0.14.0",
|
||||
"license": "BSD-3-Clause",
|
||||
"dependencies": {
|
||||
"@swc/core": "^1.5.25",
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "@flashwave/assproc",
|
||||
"version": "0.12.0",
|
||||
"version": "0.14.0",
|
||||
"description": "Personal frontend asset processing tool",
|
||||
"main": "./src/index.js",
|
||||
"scripts": {
|
||||
|
|
|
@ -23,8 +23,8 @@ module.exports = function(env) {
|
|||
process: async (task, vars) => {
|
||||
let data = fs.readFileSync(pathJoin(env.source, task.source));
|
||||
|
||||
if(typeof task.vars === 'string' && task.vars in vars)
|
||||
data = strtr(data, vars[task.vars]);
|
||||
if(typeof task.template === 'string' && task.template in vars)
|
||||
data = strtr(data, vars[task.template]);
|
||||
|
||||
if(!env.debug)
|
||||
data = await htmlminify(data, MINIFY_OPTS);
|
||||
|
|
Loading…
Reference in a new issue