Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions build/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ 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) {
rollup
.rollup({
input: opts.input,
plugins: (opts.plugins || []).concat([
json(),
buble(),
commonjs(),
nodeResolve(),
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
"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
2 changes: 2 additions & 0 deletions src/core/config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
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 @@ -64,6 +65,7 @@ export default function () {
}
}

config.version = pkgVersion
window.$docsify = config

return config
Expand Down