Skip to content

Conversation

@ikatyang
Copy link
Member

@ikatyang ikatyang commented Sep 1, 2018

Fixes #5028

Based on #5028 (comment), it seems Korean text uses conventional space so we're not going to add whitespaces between Latin and Hangul.


Prettier pr-5040
Playground link

--parser markdown

Input:

안녕하세요. 저는 Prettier을 굉장히 잘 사용하고 있습니다.
그런데 Prettier는 영어와 한글 사이에 무조건 빈 공간을 입력하고 있어요.
... ㅠㅠ

Output:

안녕하세요. 저는 Prettier을 굉장히 잘 사용하고 있습니다.
그런데 Prettier는 영어와 한글 사이에 무조건 빈 공간을 입력하고 있어요.
... ㅠㅠ

  • I’ve added tests to confirm my change works.
  • (If changing the API or CLI) I’ve documented the changes I’ve made (in the docs/ directory)
  • I’ve read the contributing guidelines.

}

const json = JSON.stringify(
require(id.replace(/^\0commonjs-proxy:/, "")),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where does this \0commonjs-proxy: come from?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rollup-plugin-commonjs I guess?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah okay, I was just confused

// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`cjk.md - markdown-verify 1`] = `
exports[`cj.md - markdown-verify 1`] = `
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about renaming these to chinese-japanese.md and korean.md so it’s clearer at first glance what they’re testing?

Or are cj and k common abbreviations?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've seen CJK, but never CJ and K as separate abbreviations

@ikatyang ikatyang merged commit 9120689 into prettier:master Sep 2, 2018
@ikatyang ikatyang deleted the fix/markdown/korean-whitespace branch September 2, 2018 08:20
@ikatyang ikatyang added this to the 1.15 milestone Oct 25, 2018
@lock lock bot added the locked-due-to-inactivity Please open a new issue and fill out the template instead of commenting. label Jan 23, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jan 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

locked-due-to-inactivity Please open a new issue and fill out the template instead of commenting.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants