How to use the @node-minify/utils.utils.setFileNameMin function in @node-minify/utils

To help you get started, we’ve selected a few @node-minify/utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github srod / node-minify / packages / core / src / setup.js View on Github external
const checkOutput = (input, output, publicFolder, replaceInPlace) => {
  let reg = new RegExp('\\$1');
  if (reg.test(output)) {
    if (Array.isArray(input)) {
      const outputMin = input.map(file =>
        utils.setFileNameMin(file, output, replaceInPlace ? null : publicFolder, replaceInPlace)
      );
      return { output: outputMin };
    } else {
      return { output: utils.setFileNameMin(input, output, replaceInPlace ? null : publicFolder, replaceInPlace) };
    }
  }
};
github srod / node-minify / packages / core / src / setup.js View on Github external
const outputMin = input.map(file =>
        utils.setFileNameMin(file, output, replaceInPlace ? null : publicFolder, replaceInPlace)
      );