Skip to content

Commit

Permalink
fix: ssr package dep, fixed docsifyjs#605
Browse files Browse the repository at this point in the history
  • Loading branch information
QingWei-Li committed Oct 31, 2018
1 parent b3b6116 commit 2bc880d
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 126 deletions.
12 changes: 5 additions & 7 deletions build/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,12 @@ const isProd = process.env.NODE_ENV === 'production'
const version = process.env.VERSION || require('../package.json').version
const chokidar = require('chokidar')
const path = require('path')
const json = require('rollup-plugin-json')

const build = function(opts) {
const build = function (opts) {
rollup
.rollup({
input: opts.input,
plugins: (opts.plugins || []).concat([
json(),
buble(),
commonjs(),
nodeResolve(),
Expand All @@ -25,7 +23,7 @@ const build = function(opts) {
})
])
})
.then(function(bundle) {
.then(function (bundle) {
var dest = 'lib/' + (opts.output || opts.input)

console.log(dest)
Expand All @@ -35,11 +33,11 @@ const build = function(opts) {
strict: false
})
})
.catch(function(err) {
.catch(function (err) {
console.error(err)
})
}
const buildCore = function() {
const buildCore = function () {
build({
input: 'src/core/index.js',
output: 'docsify.js'
Expand All @@ -53,7 +51,7 @@ const buildCore = function() {
})
}
}
const buildAllPlugin = function() {
const buildAllPlugin = function () {
var plugins = [
{name: 'search', input: 'search/index.js'},
{name: 'ga', input: 'ga.js'},
Expand Down
116 changes: 0 additions & 116 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@
"rollup-plugin-async": "^1.2.0",
"rollup-plugin-buble": "^0.18.0",
"rollup-plugin-commonjs": "^8.2.6",
"rollup-plugin-json": "^3.1.0",
"rollup-plugin-node-resolve": "^3.0.0",
"rollup-plugin-replace": "^2.0.0",
"rollup-plugin-uglify": "^2.0.1",
Expand Down
1 change: 1 addition & 0 deletions packages/docsify-server-renderer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
},
"dependencies": {
"debug": "^2.6.8",
"docsify": "^4.8.0",
"node-fetch": "^1.7.0",
"resolve-pathname": "^2.1.0"
}
Expand Down
2 changes: 0 additions & 2 deletions src/core/config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import {merge, hyphenate, isPrimitive, hasOwn} from './util/core'
import {version as pkgVersion} from './../../package.json'

export default function () {
const config = merge(
Expand Down Expand Up @@ -65,7 +64,6 @@ export default function () {
}
}

config.version = pkgVersion
window.$docsify = config

return config
Expand Down

0 comments on commit 2bc880d

Please sign in to comment.