The implementation of bind method

Before reading this article, you should call or apply , the principle of the new operator, currification, and Prototype chain mechanism Have a certain understanding. 1. Principle of bind method When fn(p1,p2,p3) calls the bind method, fn.bind(obj) will return a function bind FN with this pointing to obj. Bindfn is the same as the function body ...

Posted by worldofcarp on Sun, 14 Jun 2020 08:07:18 +0200

Check if the user is using IE

This article is translated from: Check if user is using IE I am calling a function like the one below by clicking on div s with a certain class. Is there a way I can check when starting the function if a user is using Internet Explorer and abort / cancel it if they are using other browsers so that ...

Posted by munky334 on Sun, 14 Jun 2020 04:15:45 +0200

ReactNative: Component encapsulation (e.g. secondary menu components)

1. Introduction Previously, the basic API and UI components of RN are introduced. These components exist in the form of granularity in complex composite components. How to effectively and reasonably use them for packaging is very necessary.There are many benefits to developing composite components, most notably reuse and independent functional ...

Posted by farkewie on Fri, 12 Jun 2020 04:17:07 +0200

Intelligent Transportation Development New Planning under New Capital Construction: Intelligent Tunnel Monitoring Visualization System

Preface With the development of the contemporary economy, the transportation environment is getting more and more tense, together with the transportation needs in mountainous areas, the development of tunnel traffic construction is in the ascendant.Tunnel traffic planning is becoming more and more complete, but there are some inadequacies in mo ...

Posted by geo3d on Wed, 10 Jun 2020 18:45:20 +0200

When the back end throws 100000 pieces of data to you at one time, as a front-end engineer, what should you do?

Some time ago, a friend asked me about a problem their company encountered. He said that the back-end didn't realize paging function for some reason, so he returned 20000 pieces of data at a time, and let the front-end display them in the user interface with select component. After listening, I immediately understood his confusion. If the 20000 ...

Posted by rhodry_korb on Wed, 10 Jun 2020 04:35:32 +0200

Record es6,class

The basic syntax summary of ES6 | class Class and module, the default is strict mode, so you do not need to use strict to specify the running mode. As long as your code is written in classes or modules, only strict patterns are available. Considering that all code in the future is actually running in mo ...

Posted by edup_pt on Tue, 09 Jun 2020 08:40:08 +0200

Basic use of dayjs time processing library

Day.js Is a lightweight JavaScript time and date processing library, and Moment.js The API design of is consistent. This article only introduces some common operations. For details of internationalization, plug-ins, customization and other advanced contents, please refer to the official documents. Its main characteristics are as follows: A ...

Posted by bond00 on Wed, 03 Jun 2020 18:23:55 +0200

Using the object-oriented method to write the component of carousel chart, which can be reused

First, set the html file of the carousel chart. The basic structure is as follows. At the same time, some jQuery methods are used in it. Therefore, jQuery files need to be introduced. Only div with id of banner is required, and other structures can be added as needed. If you want to set the left and right buttons, you need to add the class &quo ...

Posted by direland on Wed, 03 Jun 2020 17:18:22 +0200

Understand this thoroughly

This is one of the most commonly used keywords when we write code. Even so, it is also the most easily headache keyword for JavaScript. So what is this? If you know the execution context, you will know that this is actually an attribute of the execution context object: executionContext = { scopeChain:[ ... ], VO:{ ... }, ...

Posted by Xoom3r on Wed, 03 Jun 2020 07:45:05 +0200

Adaptive page arrangement of a bunch of pictures

Recently, we are developing a page to display pictures in batches. The adaptive arrangement of pictures is an unavoidable problem After paying for a lot of hair, I finally finished the picture arrangement and encapsulated it into components. The final effect is as follows     1, Design ideas In order to make the structure clear, I process the ...

Posted by coreycollins on Mon, 01 Jun 2020 05:48:42 +0200