dts: declarations from vite-plugin-dts, tsc and tsdown's .d.cts are not augmented
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- rust, typescript, vite
- Área
- build-system, tooling
Línea de trabajo
Start by reading the dts plugin implementation around generateBundle and compare it with the writeBundle behavior described for vite-plugin-dts and the separate tsdown CJS declaration pass. Reproduce the Vite and tsdown cases using the versions and outputs listed in the issue, then determine which proposed integration point can cover declarations written outside the bundle. Done means generated .d.ts and .d.cts files receive the required augmentation in these cases.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Found while reviewing #683 (the README now says this; this issue tracks support).
The dts plugin only sees declarations that are in the bundle at generateBundle. These are written outside it, so libraries built with them still ship plain classes and consumers fail with NG2012, as in #681:
| generator | why it is missed |
|---|---|
vite-plugin-dts 5.x (unplugin-dts) |
writes .d.ts with fs.writeFile in writeBundle, after generateBundle |
tsc |
writes files itself |
tsdown format: 'cjs' / dual |
builds .d.cts in a separate pass that leaves out user plugins; only .d.mts is augmented |
Checked with Vite 8.3.6 lib mode + vite-plugin-dts 5.1.2 (0 ɵ members in every .d.ts), and tsdown 0.23.7 esm+cjs (.d.mts augmented, .d.cts plain).
Possible directions: a writeBundle / closeBundle pass that rewrites .d.ts files on disk in the output dir, an exported helper users can call from tsdown's build:done hook, or an upstream hook in tsdown's cjs dts pass.
- Lenguaje dominante
- Rust
- Estrellas
- 245
- Forks
- 26
- Merge medio
- 1 d 42 min
- PR fusionados (30 d)
- 83
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de voidzero-dev/oxc-angular-compiler
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
voidzero-dev/oxc-angular-compiler#686 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
voidzero-dev/oxc-angular-compiler#693 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
voidzero-dev/oxc-angular-compiler#692 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 43/100
voidzero-dev/oxc-angular-compiler#691 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 3/5 1-2 días Aptitud para principiantes 72/100
voidzero-dev/oxc-angular-compiler#690 ·
Los mantenedores suelen responder en 1 día
Todos los issues de voidzero-dev/oxc-angular-compiler
Issues similares
-
bug good first issue help wanted linux macos testing
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 1 día
-
area: app type: test
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
Los mantenedores suelen responder en 1 día
-
bug priority: medium
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
storytold/photocraft#12706 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
IngvarConsulting/unica#2822 ·
Los mantenedores suelen responder en 1 día