瀏覽代碼

debug share

stanley-king 7 年之前
父節點
當前提交
3cb4d105ff

+ 2 - 5
config/dev.env.js

@@ -1,7 +1,4 @@
-var merge = require('webpack-merge')
-var prodEnv = require('./prod.env')
-
-module.exports = merge(prodEnv, {
+module.exports = {
     NODE_ENV: '"development"',
     API_ROOT: '"http://p.lrlz.com"'
-})
+}

+ 12 - 14
config/index.js

@@ -9,16 +9,8 @@ module.exports = {
     assetsSubDirectory: 'mshop',
     assetsPublicPath: './',
     productionSourceMap: true,
-    // Gzip off by default as many popular static hosts such as
-    // Surge or Netlify already gzip all static assets for you.
-    // Before setting to `true`, make sure to:
-    // npm install --save-dev compression-webpack-plugin
     productionGzip: false,
     productionGzipExtensions: ['js', 'css'],
-    // Run the build command with an extra argument to
-    // View the bundle analyzer report after build finishes:
-    // `npm run build --report`
-    // Set to `true` or `false` to always turn it on or off
     bundleAnalyzerReport: process.env.npm_config_report
   },
   dev: {
@@ -28,11 +20,17 @@ module.exports = {
     assetsSubDirectory: 'mshop',
     assetsPublicPath: '/',
     proxyTable: {},
-    // CSS Sourcemaps off by default because relative paths are "buggy"
-    // with this option, according to the CSS-Loader README
-    // (https://github.com/webpack/css-loader#sourcemaps)
-    // In our experience, they generally work as expected,
-    // just be aware of this issue when enabling this option.
     cssSourceMap: false
-  }
+  },
+    test: {
+        env: require('./test.env'),
+        index: path.resolve(__dirname, '../dist/index.html'),
+        assetsRoot: path.resolve(__dirname, '../dist'),
+        assetsSubDirectory: 'mshop',
+        assetsPublicPath: './',
+        productionSourceMap: true,
+        productionGzip: false,
+        productionGzipExtensions: ['js', 'css'],
+        bundleAnalyzerReport: process.env.npm_config_report
+    }
 }

+ 4 - 6
config/test.env.js

@@ -1,6 +1,4 @@
-var merge = require('webpack-merge')
-var devEnv = require('./dev.env')
-
-module.exports = merge(devEnv, {
-  NODE_ENV: '"testing"'
-})
+module.exports = {
+    NODE_ENV: '"testing"',
+    API_ROOT: '"http://a.lrlz.com"'
+}

File diff suppressed because it is too large
+ 1 - 1
dist/index.html


File diff suppressed because it is too large
+ 0 - 2
dist/mshop/js/app.a6e8bf2088c3c5de674b.js


File diff suppressed because it is too large
+ 0 - 1
dist/mshop/js/app.a6e8bf2088c3c5de674b.js.map


File diff suppressed because it is too large
+ 2 - 0
dist/mshop/js/app.d3196d9bee0d1c823d5f.js


File diff suppressed because it is too large
+ 1 - 0
dist/mshop/js/app.d3196d9bee0d1c823d5f.js.map


File diff suppressed because it is too large
+ 2 - 2
dist/mshop/js/manifest.c143cc8a0a59bd0d6406.js


File diff suppressed because it is too large
+ 1 - 1
dist/mshop/js/manifest.c143cc8a0a59bd0d6406.js.map


+ 1 - 1
src/components/blocks/block_list.vue

@@ -51,7 +51,7 @@
                 shareMsg = {
                     title: title,
                     desc: '丽人丽妆 内买商城',
-                    link: 'http://p.lrlz.com/mobile/index.php?act=mshop&op=special&special_id=' + this.special_id + "&title=" + title,
+                    link: 'http://p.lrlz.com/mobile/index.php?act=mshop&op=special&special_id=' + this.special_id + "&title=" + encodeURIComponent(title),
                     img_url: 'http://p.lrlz.com/data/resource/mobile/defimg/panda.jpeg'
                 };
             } else {