fix: emojis in titles not working correctly and update (#1016)

the doc(add a note)
This commit is contained in:
Koy
2020-02-14 12:51:07 +05:30
committed by GitHub
parent 0e4cdad73e
commit b3d9b966df
2 changed files with 8 additions and 3 deletions
+2
View File
@@ -2,6 +2,8 @@
docsify extends Markdown syntax to make your documents more readable.
> Note: For the special code syntax cases, you'd better put them within a code backticks to avoid any conflicting from configurations or emojis.
## important content
Important content like:
+6 -3
View File
@@ -21,9 +21,12 @@ export function getAndRemoveConfig(str = '') {
str = str
.replace(/^'/, '')
.replace(/'$/, '')
.replace(/(?:^|\s):([\w-]+)=?([\w-]+)?/g, (m, key, value) => {
config[key] = (value && value.replace(/"/g, '')) || true
return ''
.replace(/(?:^|\s):([\w-]+:?)=?([\w-]+)?/g, (m, key, value) => {
if(key.indexOf(':') === -1){
config[key] = (value && value.replace(/"/g, '')) || true
return ''
}
return m
})
.trim()
}