withastro / compiler

The Astro compiler. Written in Go. Distributed as WASM.
Other
502 stars 59 forks source link

<td> in <a href={variable}>{variable}</a> error #958

Open miya-spit opened 10 months ago

miya-spit commented 10 months ago

Astro Info

Astro                    v4.2.4
Node                     v20.11.0
System                   Windows (x64)
Package Manager          pnpm
Output                   static
Adapter                  none
Integrations             none

If this issue only occurs in one browser, which browser is a problem?

Edge

Describe the Bug

I have found a bug in Astro 4.2.7. When placing an tag inside a tag within a

, and using variables for its attributes and enclosed text, the tag is incorrectly positioned outside the
tag. The same issue occurs with and tags.

GFIlEa7bwAA33ly

What's the expected result?

<a> does not go out of <table> and is output correctly.

Link to Minimal Reproducible Example

https://stackblitz.com/edit/withastro-astro-guu8qe?file=src%2Fpages%2Findex.astro

Participation

  • [ ] I am willing to submit a pull request for this issue.
MoustaphaDev commented 9 months ago

Thanks for reporting this! I'll move this to the compiler repo to track it there