The contents of my index.d.ts
file are as follows:
declare module 'mytypes' {
interface Constructor<T> {
new (...args: any[]): T;
}
//etc.
When working in VSCode, I noticed the keyword "interface" is being highlighted:
https://i.sstatic.net/Wbfug.png
A parsing error occurs with the following message: Only declares and type imports are allowed inside declare module
1 | declare module 'someproject' {
> 2 | interface Constructor<T> {
| ^
3 | new (...args: any[]): T;
4 | }
5 |eslint
This seems to be related to an eslint error, but it's unclear which rule triggered this issue based on the error message.