-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(es/codegen): Use raw value for emitting JSX text (#9762)
**Related issue:** - Closes #9758
- Loading branch information
1 parent
fa80a1e
commit b83c44f
Showing
6 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
swc_ecma_codegen: patch | ||
swc_core: patch | ||
--- | ||
|
||
fix(es/codegen): use raw value for emitting JSX text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
crates/swc_ecma_codegen/tests/fixture/issue-9758/input.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import React from 'react'; | ||
|
||
export function Test() { | ||
return ( | ||
<div className={test}> | ||
<span>> 右上角设置</span> | ||
<span>> 保证金管理</span> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from 'react'; | ||
export function Test() { | ||
return (<div className={test}> | ||
<span>> 右上角设置</span> | ||
<span>> 保证金管理</span> | ||
</div>); | ||
} |
4 changes: 4 additions & 0 deletions
4
crates/swc_ecma_codegen/tests/fixture/issue-9758/output.min.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import React from"react";export function Test(){return(<div className={test}> | ||
<span>> 右上角设置</span> | ||
<span>> 保证金管理</span> | ||
</div>)} |