Skip to content

Commit

Permalink
Update minor devDependencies and switch to lockfile v2
Browse files Browse the repository at this point in the history
  • Loading branch information
XhmikosR committed Apr 8, 2023
1 parent 8fc1100 commit 0bbdf6c
Show file tree
Hide file tree
Showing 3 changed files with 13,710 additions and 3,053 deletions.
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const staticify = (root, options) => {

const files = fs.readdirSync(directory);

files.forEach(file => {
for (const file of files) {
const absFilePath = path.posix.join(directory, file);
const stat = fs.statSync(absFilePath);

Expand All @@ -68,7 +68,7 @@ const staticify = (root, options) => {
} else if (stat.isFile()) {
vers[`/${path.posix.relative(root, absFilePath)}`] = {absFilePath};
}
});
}

return vers;
};
Expand Down Expand Up @@ -140,7 +140,7 @@ const staticify = (root, options) => {
const replacePaths = fileContents => {
return Object.keys(versions).sort((a, b) => {
return b.length - a.length;
// eslint-disable-next-line unicorn/no-reduce
// eslint-disable-next-line unicorn/no-array-reduce
}).reduce((f, url) => {
return f.replace(new RegExp(url, 'g'), getVersionedPath(url));
}, fileContents);
Expand Down

0 comments on commit 0bbdf6c

Please sign in to comment.