Plug in mechanism in Nuxt (integrating axios example & principle analysis)

1. What is the plug-in mechanism? nuxt provides plug-ins to enhance or control existing programs. 1.1 steps of writing plug-ins 1.1.1 step 1: Create js file in / plugins / 1.1.2 step 2: Register my.js in the file nuxt.config.js /**Diffuse Road*/ plugins: [ {src:'~/plugins/my.js'} ], 1.1.3 step 3: Access any component to view the co ...

Posted on Thu, 19 Mar 2020 02:08:38 -0700 by scarface222

Detailed explanation of mockjs process for recording simulation data for vue project manufacturing and development environment

Requirement: no server at all. It can achieve the same effect as connecting to the server. It does not change the interface, but only writes data Scenario: I need to implement a function. Before, the project was directly connected with the background interface. Now I am working at home. Then I want t ...

Posted on Mon, 16 Mar 2020 01:11:51 -0700 by sebnewyork

Common methods of using axios to send requests in React

Install and introduce axios dependency in React To use axios request in React project, you need to install axios first: npm install axios --save Then use typescript to import axios dependency in react file: import axios from 'axios'; GET request with axios There are two ways to use GET requests ...

Posted on Tue, 03 Mar 2020 22:45:51 -0800 by shane18

vue network request demo

Wait for demo asynchronously:   axios-demo: Local data display: <!-- Local data display --> <ul v-show="isShowNativeResult"> <li v-for="(data,index) in datas"> <span> {{data.name}} </span> <span style="margin-left:10px; ...

Posted on Tue, 25 Feb 2020 07:26:53 -0800 by jrforrester

GraphQL Real Time Bitcoin Market [NodeJS]

In this article, we'll learn how to use Node.js to develop a GraphQL API for bitcoin real-time price quotes. Bitcoin development related links: c#Bitcoin Development Details Detailed Java Bitcoin Development PHP Bitcoin Development Details Bitcoin Data Analysis Tool Bitcoin PHP Offline Development Kit Omni/USDT Java Development Package 1. C ...

Posted on Mon, 24 Feb 2020 16:58:07 -0800 by srdva59

[Spring Boot + Vue front and back separation - book management Demo] - [2] main interface book information display

👉 [Spring Boot + Vue front and back end separation - library management Demo] - [1] environment preparation Article directory 1, Main interface style 2, The binding of menu and router to realize page Jump 1. Create new 'BookManager.vue (query book page), BookUpdate.vue (modify book information pag ...

Posted on Tue, 18 Feb 2020 05:17:53 -0800 by alexu'

Spring Boot + Vue separate front and back using Element rendering login interface

Hello, welcome to the program workplace, where you need to improve technology, career planning, personal growth, sideline development and other articles. Learn and improve with more small partners. Last article talked about login interceptors. It talked about two kinds of interceptors, front-end ...

Posted on Tue, 18 Feb 2020 01:42:01 -0800 by hybmg57

axios principle

1: Learn about axios Basic concepts: axios is an HTTP client based on promise for browsers and Node.js, or axios is an asynchronous Ajax request Library Based on promiseFeatures: (gitHub has a detailed introduction) 2: axios principle In essence, Axios is the function returned by Axios.prototype ...

Posted on Thu, 13 Feb 2020 23:17:06 -0800 by calevans

Why use promise

Original text: Why use promise   cause As we all know, the most headache of front-end development is to deal with asynchronous requests. Continue to write functions in the successful callback function, and in the long run, callback hell has formed. function load() { $.ajax({ url: 'xxx.com', data: 'jsonp' ...

Posted on Fri, 31 Jan 2020 13:30:37 -0800 by sdotsen

Design a perfect front-end authentication scheme from 0 to 1

Vue front-end authentication scheme, front-end and back-end separation Technology stack Front end Vue family bucket, backstage.net. requirement analysis Front end route authentication, shield address bar intrusion Routing data is managed by the background, and the front end only loads routes asynchronously according to fixed rules Authority co ...

Posted on Sat, 18 Jan 2020 19:29:31 -0800 by pulsedriver