Files
oxc-project__oxc/apps/oxlint/fixtures/cli/svelte/context-module-script.svelte
mustafa0x aace797941 fix(linter): detect Svelte TS and module scripts correctly (#20819)
## Summary
- parse Svelte <script> attributes instead of broad substring checks
- detect both module and context="module" scripts when creating partial
JS sources
- add unit and CLI coverage for module/instance scripts in both JS and
TS

## Validation
- mise x -- cargo test -p oxlint lint_svelte_
- mise x -- cargo test -p oxc_linter partial_loader::svelte

## AI usage disclosure
This PR was prepared with AI assistance (Codex). I reviewed and take
responsibility for the final changes.

---------

Co-authored-by: Cameron <cameron.clark@hey.com>
2026-04-27 10:39:04 +01:00

10 lines
94 B
Svelte

<script context="module">
debugger;
</script>
<script>
debugger;
</script>
<h1>Hello</h1>