chore: workaround vite package build error#28
chore: workaround vite package build error#28hi-ogawa wants to merge 5 commits intovitejs:rolldown-optimizerfrom
Conversation
|
The latest rolldown should be |
|
Thanks for the heads up! I'll test that with 0.12.1 |
|
Starting to check tests failure. Let me put some notes here playground/externalEDIT: fixed by #31 before//
// node_modules/.vite/deps/@vitejs_test-dep-that-requires.js?v=7ce498d7
//
import {
require_vue
} from "/node_modules/.vite/deps/chunk-ACQTEB6D.js?v=d821959b";
import {
require_slash
} from "/node_modules/.vite/deps/chunk-PNJKIXPP.js?v=d821959b";
// ../../node_modules/.pnpm/@vitejs+test-dep-that-requires@file+playground+external+dep-that-requires_typescript@5.2.2/node_modules/@vitejs/test-dep-that-requires/index.js
var { version } = require_vue();
var slash3 = require_slash();
document.querySelector("#required-vue-version").textContent = version;
document.querySelector("#required-slash3-exists").textContent = !!slash3("foo/bar");
//# sourceMappingURL=@vitejs_test-dep-that-requires.js.map
//
// node_modules/.vite/deps/chunk-ACQTEB6D.js
//
import {
__commonJS
} from "./chunk-PNJKIXPP.js";
// vite:cjs-external-facade:vue
import * as m from "vue";
var require_vue = __commonJS({
"vite:cjs-external-facade:vue"(exports, module) {
module.exports = m;
}
});
export {
require_vue
};after
import { require_slash_index } from "/node_modules/.vite/deps/slash_index--Dt2Pc4V.js?v=31538b99";
//#region ../../node_modules/.pnpm/@vitejs+test-dep-that-requires@file+playground+external+dep-that-requires_typescript@5.2.2/node_modules/@vitejs/test-dep-that-requires/index.js
const { version } = require('vue');
const slash3 = require_slash_index();
document.querySelector('#required-vue-version').textContent = version;
document.querySelector('#required-slash3-exists').textContent = !!slash3('foo/bar');
//#endregion
//# sourceMappingURL=@vitejs_test-dep-that-requires.js.mapplayground/dynamic-import(EDIT: reported upstream rolldown/rolldown#1723) before// node_modules/.vite/deps/@vitejs_test-pkg.js
import("/home/hiroshi/code/others/vite/node_modules/.pnpm/@vitejs+test-pkg@file+playground+dynamic-import+pkg/node_modules/@vitejs/test-pkg/pkg.css");after// node_modules/.vite/deps/@vitejs_test-pkg.js
// not transformed
import('./pkg.css');
// then after vite import analysis rewrite
import("/node_modules/.vite/deps/pkg.css?v=b4888b04")playground/ssr-noexternal(EDIT: fixed by rolldown/rolldown#1655) Error during ssr optimizeDeps. It looks like this is because of playground/ssr-depsProbably a same error as playground/tsconfig-jsonRolldown is throwing an error during deps scan since it uses esbuild's transform here but without user tsconfig which enables playground/alias(EDIT: reported upstream rolldown/rolldown#1722) There's an error during deps optimization It seems this alias is the problem. |
|
I made separate PRs to fix
For the remaining issues, I made a repro on rolldown repo: I'm closing this PR since the same change is included in other PR. |
Description
In addition to rolldown/rolldown#1642, it looks like
replaceConfusingTypeNamesis messing with vite package build. I haven't checked the error in a detail, but maybe it's okay to skip it for starter?I temporary included a patch for
binding.d.tstype error in the PR to verifypnpm buildsucceeds.