Skip to content

A way to make AS globals also visible to TS (for VS Code intellisense for example). #1929

@trusktr

Description

@trusktr

There doesn't seem to be a way to make @global AS variables visible to TypeScript. For example, this doesn't work:

// AS uses `@global`
@global
const foo: i32 = 123

// Try to make it visible in VS Code intellisense
declare global {
  const foo: i32
}

playground

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions