10.0.0 • Published 3 months ago

zk-types v10.0.0

Weekly downloads
-
License
LGPL-2.0-or-later
Repository
-
Last release
3 months ago

TypeScript Declarations for the ZK Framework

Demo

npm i -D typescript zk-types
npx tsc --init

Modify tsconfig.json to have:

{
    "compilerOptions": {
        "types": ["zk-types"]
    }
}

Create a TS file with whatever name (e.g., demo.ts) and start typing:

const oldPanel = zk.augment(zul.wnd.Panel.prototype, {
    onClose(): void {
        alert('Modified zul.wnd.Panel.prototype.onClose');
        return oldPanel.onClose();
    }
})

Compile with:

npx tsc