Thinking about the sequential relationship among HTML native document loading event + React\Vue life cycle + browser rendering

The cause of the incident is as follows: I have a need to add a dark mode for my blog. I need to save the user's choices in loadstorage, but to publish the content to github Pages, I need to compile it in the node environment. There will be objects such as window and localstorage that cannot be found. If I want to solve this problem, I need to ...

Posted by philipreed on Tue, 01 Feb 2022 22:15:20 +0100

Use a more readable way to set TypeScript types

Author: SARANSH KATARIA Translator: front end Xiaozhi Source: wisdomgeek There are dreams and dry goods. Wechat search [Daqian world] pays attention to this dish washing wisdom who is still washing dishes in the early morning. This article GitHub https://github.com/qq449245884/xiaozhi It has been included. There are complete test sites, ...

Posted by zarp on Tue, 01 Feb 2022 21:17:54 +0100

vue3.0 from getting started to getting into the ground -- Review components under advanced

catalogue ref reference Dynamic component Slot Custom instruction Table case summary ref reference 1. What is ref reference ref is used to assist developers in Without relying on jQuery , get the reference of DOM element or component. Each vue component instance contains a $refs object , which stores the reference of t ...

Posted by scrupul0us on Tue, 01 Feb 2022 10:45:30 +0100

A case of responsive layout -- the effect of common e-commerce pages

Due to the number of words, this blog is extracted from the author's last blog for explanation. If you want to understand the responsive layout, you can click this link to enter. The layout feature of responsive layout is to ensure that a page can show satisfactory results on all terminals. In one sentence, it is a set of scheme that runs ev ...

Posted by pp4sale on Tue, 01 Feb 2022 09:44:38 +0100

Kiner algorithm brush inscription: fast platoon and fast platoon idea (hand tearing algorithm)

Guide to series of articles Guide to series of articles preface After we are familiar with the idea and implementation principle of quick sort, we can bring a lot of inspiration and inspiration in our actual development. With the idea of double pointer walking of quick sort, we can also solve many kinds of quick sort problems. Now let's use ...

Posted by wvwisokee on Tue, 01 Feb 2022 08:41:52 +0100

Vue routing advanced usage and cases

The way of Vue middle road jump router-link Is the simplest way to achieve jump, also known as tag navigation. <router-link to='The path of the page to jump to'>text<router-link> When the browser parses it, it parses it into a label similar to. (1) Without parameters <router-link :to="{name:'home'}"><router-link& ...

Posted by AustinP on Tue, 01 Feb 2022 05:15:07 +0100

How to use Fetch API in vanilla JS

The Fetch API is used to make Ajax requests, such as calling the API or getting remote resources or HTML files from the server. In the past, I have been very frank I prefer XHR to Fetch . I was wrong. Fetch is objectively better. It does everything I need with simpler grammar. Let's see how it works. Basic Fetch API syntax # For today's ar ...

Posted by ted_chou12 on Tue, 01 Feb 2022 03:40:39 +0100

CSS learning week 2

Hi, guys, after a week's study, I learned a lot this time Let's have a look!!   catalogue Three style sheets Block element and inline element, inline block element Compound selector Intersection selector Union selector Descendant Selectors Child element selector attribute selectors Pseudo element selector Background picture ...

Posted by cpjok on Tue, 01 Feb 2022 02:10:53 +0100

[actual combat of the project, complete source code] teach you how to package components, rewrite React and learn online III

After reading this tutorial, you can learn the following knowledge points: Split components according to business requirements Knowledge of reusable components How child components receive data from parent components - in the last issue, we learned how to transfer data from parent components to child components Can use useState hoo ...

Posted by koolaid on Mon, 31 Jan 2022 22:09:36 +0100

web.xml configuration details

web.xml configuration Root label <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:jsp="http://java.sun.com/xml/ns/javaee/jsp" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app ...

Posted by env3rt on Mon, 31 Jan 2022 21:57:57 +0100