Exporting classes and interfaces to a module in typescript for the node.js package
I have one interface for Exception and one concrete class that inherits from this interface. I want to export these types to a module as a node.js package.
iexp.ts
interface IException {}
exp.ts
class Exception implements IException {}
index.ts
module AB_Company {
export IException;
export Exception;
}
export {AB_Company};
Codes below for viewing the scene. But I was unable to achieve this in order to export this module.
client will be used like this
import {AB_Company} from "AB_Company_Exception";
let exp:AB_Company.IException;
+3
source to share
No one has answered this question yet
Check out similar questions: