File tree Expand file tree Collapse file tree 4 files changed +32
-3
lines changed
Expand file tree Collapse file tree 4 files changed +32
-3
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ src=dist/MarkdownPalettes.umd.min.js
3+ dist=dist/markdown-palettes.js
4+ vue=https://cdn.jsdelivr.net/npm/vue@2.5
5+
6+ wget $vue -O $dist
7+ echo >> $dist
8+ cat $src >> $dist
9+ cat - >> $dist << EOF
10+
11+ (function(mp){
12+ 'use strict'
13+ class MarkdownPalettes {
14+ constructor (el, config = {}) {
15+ this.config = config
16+ this.editor = new Vue(mp)
17+ this.editor.\$ mount(el)
18+ }
19+ getContentParaser () {
20+ return this.editor.contentParser
21+ }
22+ }
23+ window.MarkdownPalettes = MarkdownPalettes
24+ })(MarkdownPalettes)
25+ EOF
Original file line number Diff line number Diff line change 1010 "scripts" : {
1111 "dev" : " vue-cli-service serve --open" ,
1212 "prod-test" : " vue-cli-service serve --open --mode production" ,
13- "build" : " vue-cli-service build --name MarkdownPalettes --target lib src/browserModule.js && rollup -c && cp demo.html dist" ,
13+ "build" : " vue-cli-service build --name MarkdownPalettes --target lib src/browserModule.js && rollup -c && cp demo.html dist && ./.after-build.sh " ,
1414 "build-dev" : " vue-cli-service build --name MarkdownPalettes --target lib src/browserModule.js --mode development" ,
1515 "lint" : " vue-cli-service lint" ,
1616 "lint-fix" : " vue-cli-service lint --fix" ,
Original file line number Diff line number Diff line change @@ -25,5 +25,8 @@ export default {
2525 'lodash'
2626 ]
2727 } )
28- ]
28+ ] ,
29+ watch : {
30+ include : 'src/**' ,
31+ }
2932}
Original file line number Diff line number Diff line change @@ -10,5 +10,6 @@ module.exports = {
1010 output : {
1111 libraryExport : 'default'
1212 }
13- }
13+ } ,
14+ productionSourceMap : false
1415}
You can’t perform that action at this time.
0 commit comments