Comfy-Org / Comfy-Org/ComfyUI_frontend

refactor: convert function expressions to function declarations in JobAssetsList.vue and QueueJobItem.vue

Open
#9,943 0 comments 0 reactions 1 assignee Claimed by @christian-byrne View on GitHub
developer experience
Dominant language
TypeScript
Stars
2k
Forks
699
Avg merge
1d 7h
Merged PRs (30d)
490

Description

## Summary

In PR #9549, approximately 15 new helper functions were added to `src/components/queue/job/JobAssetsList.vue` using `const fn = () => {}` (function expressions). Per [AGENTS.md rule 24](https://github.com/Comfy-Org/ComfyUI_frontend/blob/main/AGENTS.md), function declarations should be preferred over function expressions when possible.

`src/components/queue/job/QueueJobItem.vue` reportedly uses the same pattern and should be aligned in the same pass.

## Files to Update

- `src/components/queue/job/JobAssetsList.vue` — ~15 new functions added in #9549
- `src/components/queue/job/QueueJobItem.vue` — existing functions using the same expression pattern

## Work

Convert all eligible `const fn = () => {}` function expressions to `function fn() {}` declarations in the above files.

## References

- PR: https://github.com/Comfy-Org/ComfyUI_frontend/pull/9549
- Comment: https://github.com/Comfy-Org/ComfyUI_frontend/pull/9549#discussion_r2925540424
- Requested by: @christian-byrne

┆Issue is synchronized with this [Notion page](https://www.notion.so/Issue-9943-refactor-convert-function-expressions-to-function-declarations-in-JobAssetsList-vue-a-3246d73d3650818ab367fa408bf4b258) by [Unito](https://www.unito.io)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.