Prettier main (3.3.4 or 3.4.0)
Playground Link
# Options (if any):
--prose-wrap=always
Input:
這是一段很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長的段落
這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!
Output:
(main branch)
這是一段很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長的段落
這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!
Expected output:
這是一段很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長很長
很長的段落
這是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一
段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文
的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著
中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混
合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這是一
個English混合著中文的一段Paragraph!這是一個English混合著中文的一段Paragraph!這
是一個English混合著中文的一段Paragraph!這是一個English混合著中文的一
段Paragraph!這是一個English混合著中文的一段Paragraph!這是一個English混合著中文
的一段Paragraph!這是一個English混合著中文的一段Paragraph!
Note: don't break lines between "個" and "E", "h" and "混", "段" and "P", or "h" and "!".
Why?
According to https://wpt.fyi/results/css/css-text/line-breaking?label=master&label=experimental&aligned&q=segment-break-transformation- and https://drafts.csswg.org/css-text-4/#line-break-transform, browsers should not replace a newline between han characters with a space, but Chromium and WebKit do. (Only Firefox doesn't). This bug made Prettier to disable line breaking between han characters by #16691. We should re-enable this feature after that bug is fixed in both browsers.
The rendered result by your browser:
https://codepen.io/tats-u/pen/jOgpYWW
Firefox:

Chrome:

Blocked by:
Prettier main (3.3.4 or 3.4.0)
Playground Link
# Options (if any): --prose-wrap=alwaysInput:
Output:
(main branch)
Expected output:
Note: don't break lines between "個" and "E", "h" and "混", "段" and "P", or "h" and "!".
Why?
According to https://wpt.fyi/results/css/css-text/line-breaking?label=master&label=experimental&aligned&q=segment-break-transformation- and https://drafts.csswg.org/css-text-4/#line-break-transform, browsers should not replace a newline between han characters with a space, but Chromium and WebKit do. (Only Firefox doesn't). This bug made Prettier to disable line breaking between han characters by #16691. We should re-enable this feature after that bug is fixed in both browsers.
The rendered result by your browser:
https://codepen.io/tats-u/pen/jOgpYWW
Firefox:
Chrome:
Blocked by: