the tswhy logo: a question mark in a box

tswhy‽

A community effort to enrich TypeScript diagnostics.

Editing TS1060:

All diagnostics and fixes are authored in markdown. Propose any changes by editing the markdown. Additional fixes can be added. A preview of the rendered diagnostic will update when changes are made.

Once all proposed changes are made, the Propose button will submit the information and confirm raising the PR.

TS1060

The first parameter of the 'then' method of a promise must be a callback.

This is caused by the global Promise not having a compatible signature to support async/await downlevel emit.

Fix: Issue with promise library.

Either the 3rd party promise library cannot be used with TypeScript to down level emit async/await or there is a configuration issue with the library that is not allowing TypeScript to understand it will work. Consult the current documentation for the 3rd party promise library.