diff --git a/src/core/config.js b/src/core/config.js index 9d9f8e31d..e3a191157 100644 --- a/src/core/config.js +++ b/src/core/config.js @@ -47,17 +47,19 @@ export default function (vm) { return this.__themeColor; }, set themeColor(value) { - this.__themeColor = value; - console.warn( - stripIndent(/* html */ ` - $docsify.themeColor is deprecated. Use a --theme-color property in your style sheet. Example: - - `).trim() - ); + if (value) { + this.__themeColor = value; + console.warn( + stripIndent(` + $docsify.themeColor is deprecated. Use a --theme-color property in your style sheet. Example: + + `).trim() + ); + } }, },