microsoft / microsoft/TypeScript
capitalization of es2017 in error message does not match capitalization of ES2017 autocomplete suggestion
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Go
- Estrellas
- 111k
- Forks
- 14.3k
- Merge medio
- 2 d 4 h
- PR fusionados (30 d)
- 132
Descripción
If the maintainers of this repository think this issue is worth considering, I would like to contribute the fix for it.
Bug Report
🔎 Search Terms
"capital ES" "capitalization ES"
🕗 Version & Regression Information
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about capitalization.
⏯ Playground Link
Playground link with relevant code
💻 Code
const myObj = {};
Object.values(myObj);
with "Target:" set to a pre-ES2017 example, like ES5.
🙁 Actual behavior
On hover, the error message says, "Property 'values' does not exist on type 'ObjectConstructor'. Do you need to change your target library? Try changing the lib compiler option to 'es2017' or later.(2550)"
The capitalization in this error message does not match the auto-generated capital "ES2017" suggestion in VSCode when filling out the lib compiler option.
🙂 Expected behavior
For consistency, I think the error message should say, "Property 'values' does not exist on type 'ObjectConstructor'. Do you need to change your target library? Try changing the lib compiler option to 'ES2017' or later.(2550)", instead.
Here, the capital "ES2017" matches the suggested "ES2017" that appears when typing in a tsconfig.json file in VSCode.
Guía de contribución
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.
Línea de trabajo
Comienza buscando en los diagnósticos del compilador de TypeScript el error de Object.values indicado y reprodúcelo con el código enlazado del Playground orientado a ES5. Confirma que el diagnóstico usa la misma capitalización de ES2017 que muestra la finalización de VSCode y, después, verifica la redacción actualizada con el ejemplo y con un destino anterior a ES2017.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- typescript, vscode
- Área
- compilers
- Tipo de issue
- Error
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Estado de actividad
- Estancado
- Claridad
- Bien especificado
- Aptitud para principiantes
- 35/100