feat: customize the theme color

This commit is contained in:
qingwei.li 2017-02-04 23:45:35 +08:00 • committed by cinwell.li
commit 5cc9f0514c
13 changed files with 120 additions and 42 deletions

View file

@ -17,6 +17,7 @@ const OPTIONS = merge({
basePath: '',
auto2top: false,
name: '',
themeColor: '',
nameLink: window.location.pathname
}, window.$docsify)
const script = document.currentScript || [].slice.call(document.getElementsByTagName('script')).pop()
@ -35,6 +36,9 @@ if (script) {
if (OPTIONS.sidebar) OPTIONS.sidebar = window[OPTIONS.sidebar]
}
// utils
window.__docsify__ = OPTIONS
// load options
render.init(OPTIONS)