Transitioning from an old tsd.json
file to a new typings.json
file. In my previous .d.ts
file, the contents were as follows:
declare var modname: modname.modname;
declare module modname {
export interface modname {
new (): modname;
}
export interface foo {
bar: string;
}
}
declare module "mod-name" {
export = modname;
}
Encountering errors, I made adjustments by modifying the initial lines:
declare var modname: modname.modname;
declare namespace modname {
This change resulted in the error message:
TS2665: Module augmentation cannot introduce new names in the top level scope.
I wonder if there is a different way to install Typings? I've noticed some unusual scaffolding being automatically included in my definition files after installing them using:
typings install github:user/typ/mod-name/mod-name.d.ts --save