From (Introduction to ES6 standard) (3rd Edition) (by Ruan Yifeng) classic case - in continuous update
From (Introduction to ES6 standard) (3rd Edition) (by Ruan Yifeng) classic case - in continuous update
1. An example of simulating the return value of next method
function makeIterator(array){
var nextIndex = 0;
return {
next: function(){
return nextIndex < array.length ? {value: array[nextIndex++],done:false} : {value: und ...
Posted by demonicfoetus on Sat, 25 Apr 2020 21:04:40 -0700
Vue Router summary (from official website)
Vue Router summary (from official website)
1. Introduction to Vue router function
Nested route / view tables
Modular, component-based routing configuration
Routing parameters, queries, wildcards
View transition effect based on Vue.js transition system
Fine grained navigation control
Links with automatically activated CSS class es
HTML 5 histor ...
Posted by sotusotusotu on Sat, 25 Apr 2020 03:00:26 -0700
Summary -- several methods of generating unique id in JS
Occasionally in development, when it is necessary to generate a unique id, such as adding, deleting or modifying any item of the array many times, it is necessary to add a unique identifier to each item to distinguish. The following are various methods of generating unique identification collected from the network, which are summarized here for ...
Posted by fesan on Fri, 24 Apr 2020 07:13:11 -0700
Vue-based server-side rendering framework Nuxt.js case description
background
To develop a new official website (education company), the website needs to consider drainage, promotion, keyword search ranking, so the website needs to do SEO.Vue.js is a framework for building client applications that, by default, can output Vue components in a browser for DOM generation and operationsDOM, like this client-side re ...
Posted by sledgeweb on Sun, 19 Apr 2020 00:51:45 -0700
Using codemirror in vue (element) to realize code highlighting, code completion and version difference comparison
vue language is used, and component of element is used. To make an online editing code, code content is required to be input, highlighted display can be carried out, different languages can be switched, keyword completion is supported, and a code left-right comparison between different versions is required.
As for why codemirror is selected, pl ...
Posted by deltatango5 on Fri, 17 Apr 2020 01:50:42 -0700
HTML5+tracking.js for brush payment
HTML5+tracking.js for brush payment
Recently, brushing payments have become so popular that bosses are sure to keep up with the times, so there's a brushing payment program.The key technologies for front-end implementation are camera video recording, photo taking and face matching. This article will discuss how to achieve face brushing payment ...
Posted by adt2007 on Thu, 16 Apr 2020 20:34:11 -0700
Day 12 of egg learning notes: eggjs combines simple project to realize routing grouping and loading middleware on demand
1, Mind map of a normal project
It is roughly divided into three parts:
① Background management system (login required)
② Website front desk
3. api interface
The following is an example of module grouping based on Routing and controller:
"use strict";
/**
* @param {Egg.Application} app - egg application
*/
module.exports = app ...
Posted by edraynham on Thu, 16 Apr 2020 07:14:09 -0700
New Web Platform "airoot-uisys" Releases Front End Development Vitality
Writing this article is embarrassing because Noejs is the main platform for developing WEB today, and the three representative frameworks are network.Many people know and are familiar with that one of their advantages is modular development, the architecture for large projects, and the idea of data binding.I have been developing WEB for a long ...
Posted by kevinak on Tue, 14 Apr 2020 18:42:09 -0700
Handwritten a simple JQuery
Test samples
<!--Test samples-->
<body>
<div id="jq">1</div>
<div class="hello">2</div>
<div class="hello">3</div>
</body>
Why does jq use $(selector) to get DOM
How to implement native js
//It turns out that it's possible to pass in either an id selector or a class selector
document ...
Posted by mike2098 on Tue, 14 Apr 2020 07:54:06 -0700
Error in v-on handler: "TypeError: Cannot read property 'value' of undefined"
Error in v-on handler: "TypeError: Cannot read property 'value' of undefined"
Errors are reported as follows:
The above error occurred while running the Vue project because its container was initialized before it was generated.
First, check whether there are the following operations
//The original operation of fetching dom
document.getElementB ...
Posted by BenMo on Tue, 14 Apr 2020 07:35:17 -0700