kortina/vscode-markdown-notes

Tag explorer needs Chinese words support

Closed this issue · 2 comments

Describe the bug
Tag explorer does not support Chinese words, for example

#量子力学 #薛定谔方程

Screenshots
tags
There are only English tags.

Versions

  • OS: win10
  • VS Code Version: 1.52.1
  • Extension Version: v0.0.21

Hi @caihao ,

I think I've implemented a solution: use \p{L} rather than \w for capturing letters.

See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions/Unicode_Property_Escapes

Fortunately, this means that only a few lines of code need to change (namely the pattern and the flags), and that should suffice.

I'll bundle this into PR #119 , seeing as that also makes changes to the tag pattern(s).

Closed by #119