diff options
author | Yukai Huang | 2016-10-11 14:52:45 +0800 |
---|---|---|
committer | Yukai Huang | 2016-10-11 14:52:45 +0800 |
commit | 06437ccaa995afc48e30154c136c4e485ac04ae7 (patch) | |
tree | 372e905b6b512f29977a7c59e84138b51ec47edb /public/js | |
parent | 3368b57b89add8a11a2ac3c0a4061c46c98deb9e (diff) |
Manage more packages with npm and webpack
Diffstat (limited to 'public/js')
-rw-r--r-- | public/js/cover.js | 3 | ||||
-rw-r--r-- | public/js/extra.js | 1 | ||||
-rw-r--r-- | public/js/index.js | 7 | ||||
-rw-r--r-- | public/js/public.js | 2 |
4 files changed, 6 insertions, 7 deletions
diff --git a/public/js/cover.js b/public/js/cover.js index d3d3c10b..6346f144 100644 --- a/public/js/cover.js +++ b/public/js/cover.js @@ -12,6 +12,9 @@ var getHistory = historyModule.getHistory; var saveHistory = historyModule.saveHistory; var removeHistory = historyModule.removeHistory; +var saveAs = require('file-saver').saveAs; +var List = require('list.js'); + var options = { valueNames: ['id', 'text', 'timestamp', 'fromNow', 'time', 'tags', 'pinned'], item: '<li class="col-xs-12 col-sm-6 col-md-6 col-lg-4">\ diff --git a/public/js/extra.js b/public/js/extra.js index 4ec7e80f..329aa153 100644 --- a/public/js/extra.js +++ b/public/js/extra.js @@ -1,6 +1,7 @@ var hljs = require('highlight.js'); var PDFObject = require('pdfobject'); var S = require('string'); +var saveAs = require('file-saver').saveAs; //auto update last change var createtime = null; diff --git a/public/js/index.js b/public/js/index.js index 0c6bb03a..4bce2ff0 100644 --- a/public/js/index.js +++ b/public/js/index.js @@ -29,22 +29,19 @@ require('markdown-it-imsize'); /* other vendors plugin */ require('gist-embed'); require('string'); -require('highlight.js'); require('prismjs'); require('prismjs/components/prism-wiki'); -require('js-cookie'); require('to-markdown'); require('raphael'); require('js-sequence-diagrams'); require('flowchart.js'); -require('viz.js'); -require('file-saver'); +var saveAs = require('file-saver').saveAs; require('store'); require('js-url'); require('visibilityjs'); -require('list.js'); +var List = require('list.js'); require('../vendor/md-toc'); require('randomcolor'); diff --git a/public/js/public.js b/public/js/public.js index b6d4f7a0..69999de9 100644 --- a/public/js/public.js +++ b/public/js/public.js @@ -33,14 +33,12 @@ require('string'); require('highlight.js'); require('prismjs'); require('prismjs/components/prism-wiki'); -require('js-cookie'); require('to-markdown'); require('raphael'); require('js-sequence-diagrams'); require('flowchart.js'); -require('viz.js'); require('file-saver'); require('store'); require('js-url'); |