Following the recent change in https://github.com/DefinitelyTyped/DefinitelyTyped/pull/32567, some users may experience compile-time errors when referencing a library built with TypeScript that references the NodeJS definitions on DefinitelyTyped. Library authors may find that the following is now missing from the top of a declaration file output in their compilation:
/// <reference types="node" />
...
This is due to a bug in the emit behavior for declaration files. We recently split the definitions for NodeJS into multiple files included via /// <reference path="" />
tags to improve maintainability and are necessary to support newer TypeScript language features in the NodeJS definitions. Unfortunately, TypeScript's support for automatically emitting /// <reference types="" />
tags doesn't also include path references for "ambient modules". A fix is now available in our master
branch and will be available in our next nightly build.
In the meantime, what can users do to work around this change if they are using a version of TypeScript that does not have this fix?