UNPKG

wxt

Version:

⚡ Next-gen Web Extension Framework

28 lines (27 loc) 650 B
import path from "node:path"; import normalize from "normalize-path"; //#region src/core/utils/paths.ts /** * Converts system paths to normalized bundler path. On Windows, this returns * paths with `/` instead of `\`. */ function normalizePath(path) { return normalize(path); } /** * Given a normalized path, convert it to the system path style. On Windows, * switch to , otherwise use /. */ function unnormalizePath(path$1) { return path.normalize(path$1); } const CSS_EXTENSIONS_PATTERN = `+(${[ "css", "scss", "sass", "less", "styl", "stylus" ].join("|")})`; //#endregion export { CSS_EXTENSIONS_PATTERN, normalizePath, unnormalizePath };