fix title bug

This commit is contained in:
qingwei.li 2016-11-22 23:33:22 +08:00
commit bb76a1e446
2 changed files with 4 additions and 1 deletions

View file

@ -12,8 +12,10 @@ class Docsify {
constructor (opts) {
Docsify.installed = true
this.replace = true
this.opts = Object.assign({}, opts, DEFAULT_OPTS)
this.opts.title = (this.opts.title ? this.opts.sep : '') + this.opts.title
this.replace = true
this.dom = document.querySelector(this.opts.el)
if (!this.dom) {
this.dom = document.body