Giter Site home page Giter Site logo

Comments (7)

centrual avatar centrual commented on May 12, 2024

Compression means gzip, rar, zip etc. Why compression needed also how is related with this template?

If you asking minify, when you add --release to the command, it's automatically adds uglify js, so your javascript files become uglified ( uglify = minify + naming obfuscate ). Also everytime it minifies generated html file.

from cordova-template-framework7-vue-webpack.

ching2018 avatar ching2018 commented on May 12, 2024
cordova run browser -- --live-reload --release

i try to use this code to test my project
image
as you can see, when i use that code to compress, it seems to not work. but i can use the HtmlWebpackPlugin to compress html code, then these five div can display inline-block.

from cordova-template-framework7-vue-webpack.

ching2018 avatar ching2018 commented on May 12, 2024

thanks for your help, have a greate day~

from cordova-template-framework7-vue-webpack.

centrual avatar centrual commented on May 12, 2024

edit like that:

.actionBox {
  display: block;
  box-sizing: border-box !important;
}

.action {
  box-sizing: border-box !important;
}

also inline-block understand whitespace, so please don't add whitespace between action divs.

<div class="action">
  ...
</div><div class="action">
  ...
</div>

cordova run browser --release --live-reload command not available. Only use --release command for build your project for production. Samples:

cordova run browser -- --live-reload
cordova run android -- --lr
cordova build android --release

Note: -- --live-reload same as -- --lr. lr is shorthand usage.

from cordova-template-framework7-vue-webpack.

ching2018 avatar ching2018 commented on May 12, 2024

very helpful! but could you teach me to change the configure of webpack.config.js?

from cordova-template-framework7-vue-webpack.

ching2018 avatar ching2018 commented on May 12, 2024

well , i got the answer:

            rules: [{
                test: /\.css$/,
                use: [{
                    loader: "style-loader"
                }, {
                    loader: "css-loader"
                }]
            }, {
                test: /\.useable\.css$/,
                use: [{
                    loader: "style-loader/useable"
                }, {
                    loader: "css-loader"
                }]
            }, {
                test: /\.js?$/,
                loader: 'source-map-loader',
                enforce: 'pre'
            }, {
                test: /\.(png|jpe?g|gif)$/,
                loader: 'file-loader',
                options: {
                    name: '[name].[ext]?[hash]'
                }
            }, {
                test: /\.(woff2?|eot|ttf|otf)(\?.*)?$/,
                loader: 'file-loader',
                options: {
                    name: '[name].[ext]?[hash]'
                }
            }, {
                test: /\.svg$/,
                loader: 'url-loader'
            }, {
                test: /\.vue$/,
                loader: 'vue-loader',
                options: {
                    preserveWhitespace: false
                }
            }]
        },

from cordova-template-framework7-vue-webpack.

ching2018 avatar ching2018 commented on May 12, 2024

use preserveWhitespace: false in vue-loader options

from cordova-template-framework7-vue-webpack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.