ioBroker / ioBroker.javascript

Script engine for JavaScript and Blockly
MIT License
322 stars 120 forks source link

enumNames is not working on typeScript #1486

Closed BurnyBaby closed 5 months ago

BurnyBaby commented 5 months ago

I want to get the room name. I tried getObject(id, 'rooms').enumNames[0] but it gives me the error

javascript.0 (23507) script.js.common.OffeneFenster: TypeScript compilation failed: textLueftenEmpfohlen.push(roomName + " " + status + " " + obj.enumNames[0]); ^ ERROR: Property 'enumNames' does not exist on type '{ type: "meta" | "config" | "user" | "state" | "instance" | "adapter" | "channel" | "folder" | "device" | "script" | "enum" | "group" | "host" | "chart"; ts: number; from: string; common: { ...; }; ... 6 more ...; encryptedNative: string[]; }'.

In Javascript it is working.

Versions: