Skip to content

chore: add typed definitions for _G - #13

Closed
cayasde wants to merge 1 commit into
yTrev:masterfrom
cayasde:chore/typed-globals
Closed

chore: add typed definitions for _G#13
cayasde wants to merge 1 commit into
yTrev:masterfrom
cayasde:chore/typed-globals

Conversation

@cayasde

@cayasde cayasde commented Aug 4, 2025

Copy link
Copy Markdown
Contributor

why
luau currently infers _G as any. this pr adds explicit typings to improve type checking and autocompletion.

supported types:

name type
__DEV__ boolean?
__IGNORE_INSTANCES_WARNING__ boolean?
NOCOLOR boolean?

vscode setup
if you're using vscode with luau-lsp, add the following to your .vscode/settings.json:

{
    "luau-lsp.types.definitionFiles": [
        "types/_G.d.luau"
    ]
}

@cayasde cayasde closed this by deleting the head repository Jul 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant