Understand: front end cross domain problems JS solving cross domain problems VUE agent solving cross domain problems principle

What is cross domain Cross domain: a document or script in one domain attempts to request resources in another domain The broad cross domain includes the following contents: 1. Resource jump (link jump, redirect jump, form submission) 2. Resource request (internal reference, script, picture img, frame) 3.script internal requests (ajax, dom r ...

Posted on Wed, 20 May 2020 03:27:59 -0700 by lavender

vue single file component

Suffix name:. vue, the file needs to be precompiled before it can be used in the browser Note: the single file component depends on two packages, Vue loader / Vue template compiler Installation: NPM I - D Vue loader Vue template compiler <!-- App.vue Example code: --> <template> <div> <h1>VUE Single file compone ...

Posted on Sat, 16 May 2020 08:54:16 -0700 by ldsmike88

babel version reason run error, solution

Problem encountered while learning babel, run error after installing with old version of Babel naming rule. Preliminary find reason is because there are compatibility problems between different versions of Babel preset and plugin, prompting that npx babel-upgrade can be upgraded automatically, but my upgrade failed, prompting parsing error, lat ...

Posted on Mon, 11 May 2020 11:17:00 -0700 by duckduckgoose

Advanced use of react router

Use objects instead of JSX to configure routes Once written: <Router> <Route path="/" component={App}> <IndexRoute component={Dashboard} /> <Route path="about" component={About} /> <Route path="inbox" component={Inbox}> <Route path="/messages/:id" component={Message ...

Posted on Fri, 01 May 2020 13:33:25 -0700 by mickfuzz

Review web Pack: enable the extraction of dev server and common modules

github Previous articles:Review webback: skeleton building Get ready What problems do dev server need to solve? Development environment hot module replacement auto refresh debug traces to the original file. Source map interpretation To start dev server, we need to distinguish the production environment from the development environment. Pre ...

Posted on Fri, 01 May 2020 00:47:40 -0700 by seany123

Webpack installation record

There are still problems with the installation of Webpack. I'm not familiar with it. First, paste up the main running code to make a record, and then publish the latest one after testing. 1) Create a new web pack experiment folder 01-13 2) Enter project initialization in directory (npm init) 3) You can return all the way (entry point:index ...

Posted on Thu, 30 Apr 2020 10:56:45 -0700 by fxmzb123

vue (V): use of vue router

Because the Vue router is written differently in Vue 1.0 and 2.0, here we only look at the 2.0 version. Let's first look at our final results: Click the three tabs above to display the corresponding content below. First, introduce Vue router, and add the version of Vue router to dependencies in package.json, as shown in the figure: Three ...

Posted on Tue, 21 Apr 2020 08:31:02 -0700 by ikmyer

Common loader source analysis and a markdown-loader implementation

This article will take you to a simple understanding of the loader of webpack, a loader that converts md into an abstract grammar tree and then into an html string.By the way, take a brief look at the source code and workflow of several style-loader s, vue-loader s, and babel-loader s. md2html-loader source address Introduction to loader we ...

Posted on Sun, 19 Apr 2020 22:05:59 -0700 by RockyShark

The process of introducing js into html in Vue cli

How does Vue cli import js file into index.html through webpack? When a new user of vue writes a project with vue cli, he will find that index.html in the project directory does not introduce any js through the tag. Index.html is as follows: <!DOCTYPE html> <head> </meta charsets="utf-8"> </meta name='viewport' content ...

Posted on Wed, 15 Apr 2020 11:09:16 -0700 by justinh

Use ueditor in vue

Recently, I met the need to use rich text editor when I was working as a background management system. Finally, ueditor is selected. My project uses the scheme of Vue + vuex + Vue router + webpack + elementui to complete the framework construction, 1. Download the latest jsp version of UEditor official website. After the download and decompress ...

Posted on Thu, 09 Apr 2020 08:18:30 -0700 by msaspence