feat: migrate Slider with native range semantics and strict ESM declarations
This commit is contained in:
@@ -9,6 +9,24 @@ export default defineConfig({
|
||||
include: ["src"],
|
||||
entryRoot: "src",
|
||||
aliasesExclude: ["@heroui-vue/styles"],
|
||||
// ESM consumers using NodeNext require extensions even in declarations.
|
||||
// Foo.vue.js resolves Foo.vue.d.ts; plain Foo.vue only works in bundler mode.
|
||||
beforeWriteFile(filePath, content) {
|
||||
return {
|
||||
filePath,
|
||||
content: content.replace(
|
||||
/((?:from\s+|import\s*\(\s*)["'])(\.{1,2}\/[^"']+)(["'])/g,
|
||||
(_match, prefix: string, path: string, suffix: string) => {
|
||||
const target = /\.(?:[cm]?js|json|css)$/.test(path)
|
||||
? path
|
||||
: /\.ts$/.test(path)
|
||||
? path.slice(0, -3) + ".js"
|
||||
: path + ".js";
|
||||
return prefix + target + suffix;
|
||||
},
|
||||
),
|
||||
};
|
||||
},
|
||||
}),
|
||||
],
|
||||
build: {
|
||||
|
||||
Reference in New Issue
Block a user