JavaScript branch structure statement

Branch structure statement in JS JS code should be executed from top to bottom Branch structure statement: when a part is executed, select whether to execute a section of code according to the condition Conditional branch statement in JS - if There are four ways to write 1, if branch 1. if state ...

Posted by alecapone on Wed, 24 Jun 2020 00:55:41 -0700

Use ResizeObserver to monitor the size of a single element

1, API introduction ResizeObserver This is an API that can monitor the size and position changes of an element. It is a class. It provides an observer, which will be called on each resize event. Currently, chrome, safari and fireFox(pc) are basically supported. 2, General usage const resizeOb= n ...

Posted by mark_18 on Tue, 23 Jun 2020 00:43:40 -0700

Source Code Interpretation of vue-element-admin--Project Startup Process

vue-element-admin Is an excellent front-end framework, using the latest front-end technology, built-in (Vue-i18) Internationalized Solutions, Dynamic Routing (Vue Route) , State Management (Vuex) The scheme such as these makes the whole frame structure very clear.What's more, the framework also has Type ...

Posted by fekaduw on Tue, 09 Jun 2020 10:00:47 -0700

Dynamic generation of raster layouts using React short code

As a sub-process module of TerminalMACS, React Web Management, uses Ant Design Pro as the framework. The knowledge to which this article applies 1. Use of methods in style file less 2.for Loop Create Button and Raster Layout (flex Layout) 1. Final results and source links As a front-end novice, I spent several days doing this simple functio ...

Posted by transformationstarts on Sat, 23 May 2020 13:45:50 -0700

Easy to understand introduction to Deno

  1, About Deno Deno is a JavaScript/TypeScript runtime, which executes code in a secure environment by default, with excellent development experience. Deno has the following features: Default security. External code does not have access to file system, network and environment unless it is explicitly enabled. An environment ...

Posted by Japet on Wed, 20 May 2020 05:44:00 -0700

Using the TypeScript complier API

Using the TypeScript complier API Original Address Disclaimer Keep in mind that this is still an incomplete API - we set its release version to 0.5 and things will change over time.After all, there are some imperfections in the first iteration.I hope the community will give more feedback to improve the API.To allow users to convert betw ...

Posted by tzicha on Sun, 17 May 2020 17:47:43 -0700

Introduction and learning notes of Angular

Angular The performance of Google's open source JavaScript library is much higher than that of the previous version. It uses Typescript and new mode for development, so from the second version, the number of people has suddenly dropped dramatically. Technology: basic use of typescript, es6 Typescript is a superset of JavaScript. Both JavaScr ...

Posted by gokhul on Wed, 06 May 2020 05:53:50 -0700

Overview of common new features for Typescript 3.8

Write on top 3.8 added several interesting features, optimized the module part of ECMAScript, #use of private fields instead of less stringent privates, and so on. 1. Import and export methods for type restrictions (Type-Only Imports and Export) TypeScript 3.8 adds a new syntax for type-only import and export. import type { SomeThing } f ...

Posted by fahad on Sun, 19 Apr 2020 03:13:25 -0700

40 line program integrates the response of Vue3 into React for state management

This article refers to the original- http://bjbsair.com/2020-03-22/tech-info/2095/ Preface Vue next is the source warehouse of vue3. Vue3 uses lerna to divide the package, while the responsive capability @ vue/reactivity is divided into a separate package. If we want to integrate it into React, is it feasible? Let's have a try. Use example If ...

Posted by double on Tue, 24 Mar 2020 01:02:28 -0700

React Hook + TS shopping cart practice (performance optimization, closure trap, custom hook) - Zhihu

Preface This article is based on a basic shopping cart demand, step by step, to give you a deep understanding of the pit and Optimization in React Hook You can learn from this article: A kind of Practice of writing business components with React Hook + TypeScript A kind of How to use React.memo to optimize performance A kind of ...

Posted by Karamja on Fri, 20 Mar 2020 13:28:36 -0700