Skip to content

Conversation

@liangmiQwQ
Copy link
Contributor

Partial loader tries parsing the <script> tag in the code comment incorrectly

For example, we have a .vue file

<!-- <script setup lang="tsx"> -->
<script setup lang="ts">
const count = ref(0)
</script>

And the loader will regard these as script part

 -->
<script setup lang="ts">
const count = ref(0)

So this PR added some Finders for code comment to ignore the <script> in code comment, also works on .svelte and .astro files

@liangmiQwQ liangmiQwQ requested a review from camc314 as a code owner November 1, 2025 02:42
@graphite-app
Copy link
Contributor

graphite-app bot commented Nov 1, 2025

How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

@github-actions github-actions bot added A-linter Area - Linter C-bug Category - Bug labels Nov 1, 2025
@liangmiQwQ liangmiQwQ force-pushed the fix/ignore-scripts-in-comment branch from f22bf20 to fafcfaa Compare November 1, 2025 02:43
@codspeed-hq
Copy link

codspeed-hq bot commented Nov 1, 2025

CodSpeed Performance Report

Merging #15202 will not alter performance

Comparing liangmiQwQ:fix/ignore-scripts-in-comment (97f2e3b) with main (313e82e)

Summary

✅ 4 untouched
⏩ 33 skipped1

Footnotes

  1. 33 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@liangmiQwQ liangmiQwQ force-pushed the fix/ignore-scripts-in-comment branch from fa1cec3 to 97f2e3b Compare November 1, 2025 12:26
@camc314 camc314 merged commit 377e904 into oxc-project:main Nov 1, 2025
20 checks passed
@liangmiQwQ liangmiQwQ deleted the fix/ignore-scripts-in-comment branch November 2, 2025 09:53
@Boshen Boshen mentioned this pull request Nov 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-linter Area - Linter C-bug Category - Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants