• Luvit writes Lua applications like node.js


    What is luvit? It is currently a popular open source framework in Lua, a minority language. It gives developers who are used to using Lua a chance to develop with Lua like writing node.js. It is Lua’s node.js. On gitlab, the description of the project for luvit is as follows: Lua + libuv + JT […]

  • Implementation of node.js breakpoint continuation


    preface Ordinary business needs: upload pictures, Excel, etc., after all, the size of a few meters can be quickly uploaded to the server.For uploading video and other large files with the size of several hundred meters or several gigabytes, it takes a long time to wait. This leads to the corresponding solutions. When the upload […]

  • node.js Knowledge points of event polling mechanism


    Implementation of virtual reality with the help of libuv Library Summarize the event polling mechanism: it is divided into six stages 1. Timers timer stage Timer callback function for timing and execution to point 2.pending callbacks Some system operations (such as TCP error types) 3.idle,prepare 4. Poll phase (polling queue) If the polling queue is […]

  • node.js Example of adding, deleting, modifying and querying shopping cart by using mongoose to operate database


    In this paper, an example is given node.js Mongoose is used to operate the database to realize the functions of adding, deleting, modifying and querying the shopping cart. The details are as follows: 1. Database operation statement Mongoose implements the operation of each collection through model, which needs to be defined before use model:goods . […]

  • node.js Example analysis of using promise object


    In this paper, an example is given node.js How to use the promise object. The details are as follows: What is the promise object for? The asynchronous operation is expressed as the process of synchronous operation 1、 The definition of promise object let flag = true; const hello = new Promise(function (resolve, reject) { If […]

  • node.js Analysis of three methods of capturing global exception in Express


    In this paper, an example is given node.js There are three ways to catch global exception in express. The details are as follows: scene After throwing an exception in the express route, the global middleware can’t catch it. It’s necessary to write try catch in all the route functions. This kind of logic makes people […]

  • Node.js How to create an express service


    In this paper, an example is given Node.js Method to create an express service. For your reference, the details are as follows: 1. Create an httpserver server stay node.js After downloading the Windows version of node on the official website, you can install node and create a new one server.js File, start the first node […]

  • Vue Axios secondary packaging


    import axios from ‘axios’;import QS from ‘qs’; //Environment switching// if (process.env.NODE_ENV === ‘development’) {// axios.defaults.baseURL = ‘’;// } else if (process.env.NODE_ENV === ‘production’) {// axios.defaults.baseURL = ‘https://www.production.com’;// } axios.defaults.timeout = 5000;//HTTP request interceptoraxios.interceptors.request.use( config => { config.headers = { ‘Content-Type’:’application/x-www-form-urlencoded’ } return config; }, error => { return Promise.reject(error); }); //Response interceptor is exception handlingaxios.interceptors.response.use( […]

  • MySQL introduction lesson 1 creating, modifying and deleting tables


    The original text is on my GitHub, welcome to subscribe. preface I want to learn database, so I have thisMysqlSeries. This series is mainly used for my studyMysqlI take it as learning notes.Instead of starting with the knowledge of database installation, user addition and permission allocation, it focuses onMysqlTable operation, data addition, deletion, modification and […]

  • MySQL introduction lesson 2 data types


    The original text is on my GitHub, welcome to subscribe. preface This article continues to learn the first lesson of MySQL introduction “create table, change table, delete table”. To build an excellent table, it is very important to choose the appropriate data type. If the data type is not selected properly, it will not only […]

  • Today, the night team gathered by the big guys is officially established!


    Today’s article is to tell you that many powerful developers in the industry have set up a team to serve the majority of developers. Now, you may have the following questions: Why team up? What will this team bring to developers? Who are the team members? OK, let’s take 3 minutes to get to know […]

  • Using verdaccio to create NPM private library


    Using verdaccio to create NPM private library Article description This article is recorded in the language sparrow. You can see how to create NPM private library with verdaccio.