• Vue scaffold configuration agent


    Method 1: in Vue config. JS add the following configuration devServer: { Proxy: “remote server address and port number”, } explain: Advantages: simple configuration. When requesting resources, it can be sent directly to the front end (8080). Disadvantages: multiple agents cannot be configured, and it is not possible to flexibly control whether requests go through […]

  • Vue programmed route navigation and route guard


    Replace attribute of Function: control the mode of operating browser history during route jump There are two ways to write browser history: push and replace. Push is to add history, replace is to replace the current record, and push is to switch routes How to enable replace mode: news Programmed route navigation Function: without the […]

  • Vue routing usage and parameter acceptance


    Basic use of routing introduce Understanding: a route is a set of key values. Multiple routes need to be managed by a router. Front end Routing: key is the path and value is the component Basic use Install Vue router, command: NPM install — save Vue router Application plug-in: Vue use(VueRouter) Write router configuration items: […]

  • Common problems of Vue simple uploader


    catalogue How can option or query be made dynamic? How to make target dynamic? How to limit the number of uploaded files or ignore some files? How to customize the request parameters of the interface? Dynamic modificationattrsUnsuccessful problems Display of some custom verification statuses (about MD5 and MD5) On the logic of second transmission and […]

  • Front end productivity improvement Series III (vant3 vue3 mobile terminal H5 pull-down refresh, pull-up loading component packaging)


    In the daily development of mobile terminal, we often encounter the display of list and the operation of pull-up and pull-down when the amount of data becomes more and more. After entering the new company, I found many lists on the mobile terminal, but when looking at the code, I found that each list is […]

  • three. JS add 3D model


    There are only a few official geometries in three. It is very difficult to generate various models. At this time, it is an option to introduce external models. The specific introduction methods are as follows. Import dependency Click to view the code import * as THREE from “three”; import { OrbitControls } from “three/examples/jsm/controls/OrbitControls”; // […]

  • Html2canvas Usage Summary


    preface Recently, I came across a function to convert forms into pictures to save, which reminds me of a plug-in html2canvas. Here I share its usage and the process of my use Html2canvas # can capture the whole or part of the page directly in the user’s browser. This html2canvas script will be implemented when […]

  • @How much do you know about Vue / cli configuration – publicpath, outputdir, assetsdir, indexpath, filenamehashing, configurewebpack, productionsourcemap


    vue. config. JS vue. config. JS is an optional configuration file, This file exists in the root directory of the project (the same level as package. JSON). By default, there is no such file. We need to create it manually Then it will be automatically loaded by @ Vue / cli service. module.exports={ Productionsourcemap: false, […]

  • Electron packaging Vue project


    Create project clickhere Add electron builder 1. Run the command Vue add electron builder under the project directory2. After adding the electron builder, you will select the electron version and directly select the latest version: Electronic download failed Vue add electron builder will fail to download electron. Use Taobao image to download: cnpm I electron […]

  • Vue life cycle summary


    Vue life cycle summary Life cycle: 1. Also known as: life cycle callback function, life cycle function, life cycle hook. 2. What is it: some functions with special names that Vue calls for us at critical moments. 3. The name of the life cycle function cannot be changed, but the specific content of the function […]

  • Vue actual combat advanced (0) — basic preparation, project creation, actual combat ideas


    Preliminary software preparation Environment: nodejs installation Development tools: vscode installation Installation Vue and scaffold vuecli Construction project 1. Create project vue create myprojectTo create a scaffold project, you can set vuex, vuerouter, style, linter, etc 2. Install basic NPM package Do projectMandatory components: front end component library, HTTP Library Click to view the code npm […]

  • Vue3 technology sorting – update completed


    0. Preface Vue2 basic chapter link: Vue2 component development link: Vue2 advanced link: 1. Create vue3 project Official website documents: 1.1. Create with Vue cli Note: you need to ensure that your Vue cli version is above 4.5.0 View your own version of @ Vue / cli Vue -V Install or upgrade @ Vue / […]