Commit a9f0e79b by 无尘

feat: 增加公共库使用 CDN

parent 75821c86
......@@ -32,6 +32,11 @@ module.exports = {
? config.build.assetsPublicPath
: config.dev.assetsPublicPath
},
externals: {
'vue': 'Vue',
'vue-router': 'VueRouter',
'vuex': 'Vuex'
},
resolve: {
extensions: ['.js', '.vue', '.json'],
alias: {
......
......@@ -46,7 +46,7 @@ const webpackConfig = merge(baseWebpackConfig, {
filename: utils.assetsPath('css/[name].[contenthash].css'),
// Setting the following option to `false` will not extract CSS from codesplit chunks.
// Their CSS will instead be inserted dynamically with style-loader when the codesplit chunk has been loaded by webpack.
// It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
// It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
// increasing file size: https://github.com/vuejs-templates/webpack/issues/1110
allChunks: true,
}),
......
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./favicon.ico><title>好办管理平台</title><link href=./static/css/app.1c8ffcdb74d8b258c3a9cb91f1d1afbe.css rel=stylesheet></head><body style="min-width: 1400px;"><div id=app></div><script src=//web-1251519181.file.myqcloud.com/components/img-preview.2.0.00.js></script><script>// Raven.config('https://3715a345910d4c768e7a1ec14619c2d5@sentry.io/1413672').install();</script><script type=text/javascript src=./static/js/manifest.a7f3160302740c14ee7f.js></script><script type=text/javascript src=./static/js/vendor.7bffa30b60868871b0ad.js></script><script type=text/javascript src=./static/js/app.3b2b69467d53996b5dc2.js></script></body></html>
\ No newline at end of file
<!DOCTYPE html><html><head><meta charset=utf-8><link rel="shortcut icon" href=./favicon.ico><title>好办管理平台</title><link href=./static/css/app.1c8ffcdb74d8b258c3a9cb91f1d1afbe.css rel=stylesheet></head><body style="min-width: 1400px;"><div id=app></div><script src=//web-1251519181.file.myqcloud.com/lib/vue/2.6.6/vue.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js></script><script src=//web-1251519181.file.myqcloud.com/components/img-preview.2.0.00.js></script><script>// Raven.config('https://3715a345910d4c768e7a1ec14619c2d5@sentry.io/1413672').install();</script><script type=text/javascript src=./static/js/manifest.f5120413f93c065c9143.js></script><script type=text/javascript src=./static/js/vendor.34b23182008ddcb7a22f.js></script><script type=text/javascript src=./static/js/app.5e4416fcb7e95da51ebc.js></script></body></html>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(a,b,n){for(var r,t,o,i=0,u=[];i<a.length;i++)t=a[i],d[t]&&u.push(d[t][0]),d[t]=0;for(r in b)Object.prototype.hasOwnProperty.call(b,r)&&(e[r]=b[r]);for(c&&c(a,b,n);u.length;)u.shift()();if(n)for(i=0;i<n.length;i++)o=f(f.s=n[i]);return o};var a={},d={77:0};function f(c){if(a[c])return a[c].exports;var d=a[c]={i:c,l:!1,exports:{}};return e[c].call(d.exports,d,d.exports,f),d.l=!0,d.exports}f.e=function(e){var c=d[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var a=new Promise(function(a,f){c=d[e]=[a,f]});c[2]=a;var b=document.getElementsByTagName("head")[0],n=document.createElement("script");n.type="text/javascript",n.charset="utf-8",n.async=!0,n.timeout=12e4,f.nc&&n.setAttribute("nonce",f.nc),n.src=f.p+"static/js/"+e+"."+{0:"3f341add977b18a3efb0",1:"0ebe3ead93207dc78a78",2:"95e65373870423c59dc7",3:"c2fd89730cdd6d5b8904",4:"c23ab1c011f8ddc3428b",5:"d41ea5dba7a329f04b96",6:"af5f6241c09b00cd7e44",7:"7e0164566e8e00575481",8:"bb8853a5a6239a7e1349",9:"7dc467d5cfcb4cfb033f",10:"0415008ce1e9a883ceb3",11:"0a7059ea2e15c5acf938",12:"bdee76fd84034bc2d498",13:"99eba27757bf881d6c39",14:"70a11e50ec358505e2b6",15:"982c7f877d4d88d1d93b",16:"8f8e20ce84faa7e6b5e6",17:"2c76434ec01b2b5ee02f",18:"899eb9ec9050797cc2b4",19:"27c00c26337d1b0a5f29",20:"516a97da045de8173b75",21:"1218f07273b4fca490fc",22:"d249aa89b62990eb828d",23:"413b19e4c879b068a62c",24:"9d547e5255fc6330d24b",25:"c613f7ea850a38ab5967",26:"24fa9334a68a4c15b211",27:"67aff6575da1034dde97",28:"6a37c0d8bd425ec79cb7",29:"0155355dd99fffcb77d7",30:"1d1070b9cf82765f3db6",31:"af46f102606343be3a92",32:"41a1620b882cbd77f621",33:"98c9f8f46aabb33952e1",34:"a870a2a95752c259fbcb",35:"32cae9a3f9ba6b187945",36:"706cf2b1fed575cc2e7b",37:"8016d3ac07df8acaf73d",38:"419c9b68a385c260821b",39:"5a144b590087731c3653",40:"27851a220bdc8cf9de25",41:"67fc41319ca25ea2ba89",42:"0daee346d67f816b99c3",43:"9d05f4d2f06b9c6bba0e",44:"8b267f44a7d0855db1b1",45:"0c086d4c604bfae8f1e2",46:"8627c20ac6fb5b6dd47c",47:"cee4bd255fc6984e203a",48:"6d564387f233c08c800d",49:"16d7cb7cd95756ebf1a0",50:"1c8da7c7e73224e1079e",51:"b171588c2b70fec4c029",52:"10599ff77c8e1dc5cb61",53:"8802335b18fef4b4450b",54:"d1b44ac8d91eb92bf746",55:"a733127e23169fda7551",56:"91eb07cc8e7e8a4439b9",57:"b7e06a6ee4048a51a73d",58:"31750092465add0acd92",59:"133b37877d1a48ad1fd1",60:"6ff0cd2c4afde9bd8afc",61:"5b6712c4261c8c8331b1",62:"7c94a16a9482fc4a5f52",63:"81c8a522301e88b8c3f2",64:"d03865cf6990d2be8d2d",65:"d4d5eb36aca1fcd683b6",66:"6b5fc386ec869d82a1dc",67:"2d8e5c7eef8491a3cdba",68:"ba49712f562eff6edbc3",69:"e65d327b559f8fae7f73",70:"f19cdcc96fb03261fca5",71:"87a6af69154348344f0b",72:"14bd495ccecac00655be",73:"b89ad92812ac506a22b8",76:"fd376da7cdbac115205f"}[e]+".js";var r=setTimeout(t,12e4);function t(){n.onerror=n.onload=null,clearTimeout(r);var c=d[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),d[e]=void 0)}return n.onerror=n.onload=t,b.appendChild(n),a},f.m=e,f.c=a,f.d=function(e,c,a){f.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:a})},f.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return f.d(c,"a",c),c},f.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},f.p="./",f.oe=function(e){throw console.error(e),e}}([]);
\ No newline at end of file
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(a,b,n){for(var r,t,o,i=0,u=[];i<a.length;i++)t=a[i],d[t]&&u.push(d[t][0]),d[t]=0;for(r in b)Object.prototype.hasOwnProperty.call(b,r)&&(e[r]=b[r]);for(c&&c(a,b,n);u.length;)u.shift()();if(n)for(i=0;i<n.length;i++)o=f(f.s=n[i]);return o};var a={},d={77:0};function f(c){if(a[c])return a[c].exports;var d=a[c]={i:c,l:!1,exports:{}};return e[c].call(d.exports,d,d.exports,f),d.l=!0,d.exports}f.e=function(e){var c=d[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var a=new Promise(function(a,f){c=d[e]=[a,f]});c[2]=a;var b=document.getElementsByTagName("head")[0],n=document.createElement("script");n.type="text/javascript",n.charset="utf-8",n.async=!0,n.timeout=12e4,f.nc&&n.setAttribute("nonce",f.nc),n.src=f.p+"static/js/"+e+"."+{0:"bca2307edf91a137443b",1:"0ebe3ead93207dc78a78",2:"95e65373870423c59dc7",3:"c2fd89730cdd6d5b8904",4:"c23ab1c011f8ddc3428b",5:"d41ea5dba7a329f04b96",6:"af5f6241c09b00cd7e44",7:"7e0164566e8e00575481",8:"bb8853a5a6239a7e1349",9:"7dc467d5cfcb4cfb033f",10:"0415008ce1e9a883ceb3",11:"0a7059ea2e15c5acf938",12:"bdee76fd84034bc2d498",13:"99eba27757bf881d6c39",14:"70a11e50ec358505e2b6",15:"982c7f877d4d88d1d93b",16:"8f8e20ce84faa7e6b5e6",17:"2c76434ec01b2b5ee02f",18:"899eb9ec9050797cc2b4",19:"27c00c26337d1b0a5f29",20:"516a97da045de8173b75",21:"1218f07273b4fca490fc",22:"d249aa89b62990eb828d",23:"413b19e4c879b068a62c",24:"9d547e5255fc6330d24b",25:"c613f7ea850a38ab5967",26:"24fa9334a68a4c15b211",27:"67aff6575da1034dde97",28:"6a37c0d8bd425ec79cb7",29:"0155355dd99fffcb77d7",30:"1d1070b9cf82765f3db6",31:"af46f102606343be3a92",32:"41a1620b882cbd77f621",33:"98c9f8f46aabb33952e1",34:"a870a2a95752c259fbcb",35:"32cae9a3f9ba6b187945",36:"706cf2b1fed575cc2e7b",37:"8016d3ac07df8acaf73d",38:"419c9b68a385c260821b",39:"5a144b590087731c3653",40:"27851a220bdc8cf9de25",41:"67fc41319ca25ea2ba89",42:"0daee346d67f816b99c3",43:"9d05f4d2f06b9c6bba0e",44:"8b267f44a7d0855db1b1",45:"0c086d4c604bfae8f1e2",46:"8627c20ac6fb5b6dd47c",47:"cee4bd255fc6984e203a",48:"6d564387f233c08c800d",49:"16d7cb7cd95756ebf1a0",50:"1c8da7c7e73224e1079e",51:"b171588c2b70fec4c029",52:"10599ff77c8e1dc5cb61",53:"8802335b18fef4b4450b",54:"d1b44ac8d91eb92bf746",55:"a733127e23169fda7551",56:"91eb07cc8e7e8a4439b9",57:"b7e06a6ee4048a51a73d",58:"31750092465add0acd92",59:"133b37877d1a48ad1fd1",60:"6ff0cd2c4afde9bd8afc",61:"5b6712c4261c8c8331b1",62:"7c94a16a9482fc4a5f52",63:"81c8a522301e88b8c3f2",64:"d03865cf6990d2be8d2d",65:"d4d5eb36aca1fcd683b6",66:"6b5fc386ec869d82a1dc",67:"2d8e5c7eef8491a3cdba",68:"ba49712f562eff6edbc3",69:"e65d327b559f8fae7f73",70:"f19cdcc96fb03261fca5",71:"87a6af69154348344f0b",72:"14bd495ccecac00655be",73:"b89ad92812ac506a22b8",76:"fd376da7cdbac115205f"}[e]+".js";var r=setTimeout(t,12e4);function t(){n.onerror=n.onload=null,clearTimeout(r);var c=d[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),d[e]=void 0)}return n.onerror=n.onload=t,b.appendChild(n),a},f.m=e,f.c=a,f.d=function(e,c,a){f.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:a})},f.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return f.d(c,"a",c),c},f.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},f.p="./",f.oe=function(e){throw console.error(e),e}}([]);
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -8,6 +8,10 @@
<body style="min-width: 1400px;">
<div id="app"></div>
<!-- built files will be auto injected -->
<!-- 公共库引用 cdn -->
<script src="//web-1251519181.file.myqcloud.com/lib/vue/2.6.6/vue.min.js"></script>
<script src="//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js"></script>
<script src="//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js"></script>
<script src="//web-1251519181.file.myqcloud.com/components/img-preview.2.0.00.js"></script>
<!-- <script src="https://cdn.ravenjs.com/3.26.2/vue/raven.min.js" crossorigin="anonymous"></script> -->
<script>
......
......@@ -31,10 +31,8 @@
"requset": "^1.0.5",
"script-loader": "^0.7.2",
"tinymce": "^4.8.3",
"vue": "^2.5.2",
"vue-awesome-swiper": "^3.1.3",
"vue-clipboard2": "^0.2.0",
"vue-router": "^3.0.1",
"xlsx": "^0.13.5"
},
"devDependencies": {
......@@ -91,7 +89,6 @@
"vue-style-loader": "^3.0.1",
"vue-template-compiler": "^2.5.2",
"vuedraggable": "^2.17.0",
"vuex": "^3.0.1",
"webpack": "^3.6.0",
"webpack-bundle-analyzer": "^2.9.0",
"webpack-dev-server": "^2.9.1",
......
import 'babel-polyfill';
import promise from 'es6-promise';
promise.polyfill();
import Vue from 'vue';
// import Vue from 'vue';
import App from './App';
import router from './router';
import ElementUI, { Message } from 'element-ui';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment