Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Extension resolution assumes JS/TS candidates; a .vue/.svelte sibling can still diverge from the bundler

Open
#228 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
52/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
typescript, vite

Research direction

Start by locating resolveFileAtPath and the code that reads project configuration; the issue does not name file paths or tests. Check how resolve.extensions is parsed and how candidate paths are selected, then run the relevant resolver tests. Done means a base with a matching non-JS extension such as .vue or .svelte is treated as ambiguous and disclosed rather than attributed to a JS/TS candidate.

Written by the indexing model from the issue text.

Description

area: engine bug

Follow-up to #226.

What is wrong

resolveFileAtPath discloses when more than one JS/TS candidate file exists, which closes the common false-coverage case. But it only probes JS/TS suffixes (.mjs .js .mts .ts .jsx .tsx and index variants). If a project's resolve.extensions includes a non-JS framework extension (for example .vue or .svelte) and both Widget.vue and Widget.tsx exist, Vite may load Widget.vue while usabl sees a single JS candidate (Widget.tsx) and attributes it.

Why it matters

Low in practice for usabl's current React/PatternFly domain: the mis-picked .tsx would be a file the bundler does not render, so no real barrier is missed, and usabl scans .tsx/.jsx UI files anyway. Tracked so it is not forgotten if usabl targets multi-framework apps.

Fix

Parse the project's resolve.extensions and treat a base with any extra candidate (including non-JS) as ambiguous, disclosing rather than picking a JS/TS file.

Dominant language
TypeScript
Stars
0
Forks
0
Avg merge
2h 48m
Merged PRs (30d)
8

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from usabl-dev/usabl

All issues in usabl-dev/usabl

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.