Commit Graph

9 Commits

Author SHA1 Message Date
Christian Byrne
a1c54ad7aa fix: add explicit type annotations to extension callback parameters (#8966)
Fixes #8882

Adds explicit type annotations to all extension callback parameters
(`nodeCreated`, `beforeRegisterNodeDef`, `addCustomNodeDefs`) across 14
core extension files. While the types were already inferred from the
`ComfyExtension` interface, explicit annotations improve readability and
make the code self-documenting.

## Changes

- Annotate `node` parameter as `LGraphNode` in all `nodeCreated`
callbacks
- Annotate `nodeType` as `typeof LGraphNode` and `nodeData` as
`ComfyNodeDef` in all `beforeRegisterNodeDef` callbacks
- Annotate `defs` as `Record<string, ComfyNodeDef>` in
`addCustomNodeDefs`
- Add necessary type imports where missing

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-8966-fix-add-explicit-type-annotations-to-extension-callback-parameters-30b6d73d36508125b074f509aa38145f)
by [Unito](https://www.unito.io)
2026-02-20 01:26:11 -08:00
Chenlei Hu
3f4d11c63a Inplace widget to input conversion (#2588)
Co-authored-by: github-actions <github-actions@github.com>
2025-02-16 13:41:32 -05:00
Chenlei Hu
b4c59ffae1 [Refactor] useStringWidget composable (#2503) 2025-02-10 19:49:00 -05:00
pythongosssss
c77a5cab5b Add support for nested dynamic prompts (#2117) 2025-01-01 15:29:17 -05:00
Chenlei Hu
c4d3c672ad Enforce ComfyExtension types (#1718)
* Enforce extension types

* nit
2024-11-27 15:35:18 -05:00
Chenlei Hu
5611e90fda Add ts-strict-ignore plugin (#1235)
* Add ts-strict-ignore plugin

* nit

* Add to typecheck script
2024-10-12 11:56:49 -04:00
Chenlei Hu
e179f75387 Apply new code format standard (#217) 2024-07-25 10:10:18 -04:00
Chenlei Hu
acdaa6a594 Format all code / Add pre-commit format hook (#81)
* Add format-guard

* Format code
2024-07-02 13:22:37 -04:00
Chenlei Hu
40754f198a Rename (#33) 2024-06-18 14:30:56 -04:00