Skip to content

Commit 9ecaf96

Browse files
author
YuChengKai
committed
release V1.0
1 parent 6400990 commit 9ecaf96

17 files changed

+238
-18
lines changed

Algorithm/algorithm-ch.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
- [斐波那契数列](#%E6%96%90%E6%B3%A2%E9%82%A3%E5%A5%91%E6%95%B0%E5%88%97)
3131
- [0 - 1背包问题](#0---1%E8%83%8C%E5%8C%85%E9%97%AE%E9%A2%98)
3232
- [最长递增子序列](#%E6%9C%80%E9%95%BF%E9%80%92%E5%A2%9E%E5%AD%90%E5%BA%8F%E5%88%97)
33+
- [字符串相关](#%E5%AD%97%E7%AC%A6%E4%B8%B2%E7%9B%B8%E5%85%B3)
3334

3435
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
3536

@@ -880,5 +881,3 @@ function lis(n) {
880881

881882
如果你对于 Trie 树还不怎么了解,可以前往 [这里](../DataStruct/dataStruct-zh.md#trie) 阅读
882883

883-
## KMP
884-

DataStruct/dataStruct-en.md

+35
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,38 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [Stack](#stack)
6+
- [Conception](#conception)
7+
- [Implementation](#implementation)
8+
- [Application](#application)
9+
- [Queues](#queues)
10+
- [concept](#concept)
11+
- [implementation](#implementation)
12+
- [Singly-linked Queue](#singly-linked-queue)
13+
- [Circular Queue](#circular-queue)
14+
- [Linked List](#linked-list)
15+
- [Concept](#concept)
16+
- [Implementation](#implementation-1)
17+
- [Tree](#tree)
18+
- [Binary Tree](#binary-tree)
19+
- [Binary Search Tree](#binary-search-tree)
20+
- [Implementation](#implementation-2)
21+
- [AVL Tree](#avl-tree)
22+
- [Concept](#concept-1)
23+
- [Implementation](#implementation-3)
24+
- [Trie](#trie)
25+
- [Concept](#concept-2)
26+
- [Implementation](#implementation-4)
27+
- [Disjoint Set](#disjoint-set)
28+
- [Concept](#concept-3)
29+
- [Implementation](#implementation-5)
30+
- [Heap](#heap)
31+
- [Concept](#concept-4)
32+
- [Implementation of Max Binary Heap](#implementation-of-max-binary-heap)
33+
34+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
35+
136
# Stack
237

338
## Conception

DataStruct/dataStruct-zh.md

+9-3
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,18 @@
1818
- [二叉树](#%E4%BA%8C%E5%8F%89%E6%A0%91)
1919
- [二分搜索树](#%E4%BA%8C%E5%88%86%E6%90%9C%E7%B4%A2%E6%A0%91)
2020
- [实现](#%E5%AE%9E%E7%8E%B0-3)
21+
- [AVL 树](#avl-%E6%A0%91)
22+
- [概念](#%E6%A6%82%E5%BF%B5-3)
23+
- [实现](#%E5%AE%9E%E7%8E%B0-4)
2124
- [Trie](#trie)
22-
- [概念](#%E6%A6%82%E5%BF%B5-3)
23-
- [实现](#%E5%AE%9E%E7%8E%B0-4)
24-
- [并查集](#%E5%B9%B6%E6%9F%A5%E9%9B%86)
2525
- [概念](#%E6%A6%82%E5%BF%B5-4)
2626
- [实现](#%E5%AE%9E%E7%8E%B0-5)
27+
- [并查集](#%E5%B9%B6%E6%9F%A5%E9%9B%86)
28+
- [概念](#%E6%A6%82%E5%BF%B5-5)
29+
- [实现](#%E5%AE%9E%E7%8E%B0-6)
30+
- [](#%E5%A0%86)
31+
- [概念](#%E6%A6%82%E5%BF%B5-6)
32+
- [实现大根堆](#%E5%AE%9E%E7%8E%B0%E5%A4%A7%E6%A0%B9%E5%A0%86)
2733

2834
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
2935

Framework/framework-en.md

+22
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,25 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [MVVM](#mvvm)
6+
- [Dirty Checking](#dirty-checking)
7+
- [Data hijacking](#data-hijacking)
8+
- [Proxy vs. Obeject.defineProperty](#proxy-vs-obejectdefineproperty)
9+
- [Routing principle](#routing-principle)
10+
- [Virtual Dom](#virtual-dom)
11+
- [Why Virtual Dom is needed](#why-virtual-dom-is-needed)
12+
- [Virtual Dom algorithm introduction](#virtual-dom-algorithm-introduction)
13+
- [Virtual Dom algorithm implementation](#virtual-dom-algorithm-implementation)
14+
- [recursion of the tree](#recursion-of-the-tree)
15+
- [checking property changes](#checking-property-changes)
16+
- [Algorithm Implementation for Detecting List Changes](#algorithm-implementation-for-detecting-list-changes)
17+
- [Iterating and Marking Child Elements](#iterating-and-marking-child-elements)
18+
- [Rendering Difference](#rendering-difference)
19+
- [The End](#the-end)
20+
21+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
22+
123
# MVVM
224

325
MVVM consists of the following three contents

Framework/framework-zh.md

+22
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,25 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [MVVM](#mvvm)
6+
- [脏数据检测](#%E8%84%8F%E6%95%B0%E6%8D%AE%E6%A3%80%E6%B5%8B)
7+
- [数据劫持](#%E6%95%B0%E6%8D%AE%E5%8A%AB%E6%8C%81)
8+
- [Proxy 与 Obeject.defineProperty 对比](#proxy-%E4%B8%8E-obejectdefineproperty-%E5%AF%B9%E6%AF%94)
9+
- [路由原理](#%E8%B7%AF%E7%94%B1%E5%8E%9F%E7%90%86)
10+
- [Virtual Dom](#virtual-dom)
11+
- [为什么需要 Virtual Dom](#%E4%B8%BA%E4%BB%80%E4%B9%88%E9%9C%80%E8%A6%81-virtual-dom)
12+
- [Virtual Dom 算法简述](#virtual-dom-%E7%AE%97%E6%B3%95%E7%AE%80%E8%BF%B0)
13+
- [Virtual Dom 算法实现](#virtual-dom-%E7%AE%97%E6%B3%95%E5%AE%9E%E7%8E%B0)
14+
- [树的递归](#%E6%A0%91%E7%9A%84%E9%80%92%E5%BD%92)
15+
- [判断属性的更改](#%E5%88%A4%E6%96%AD%E5%B1%9E%E6%80%A7%E7%9A%84%E6%9B%B4%E6%94%B9)
16+
- [判断列表差异算法实现](#%E5%88%A4%E6%96%AD%E5%88%97%E8%A1%A8%E5%B7%AE%E5%BC%82%E7%AE%97%E6%B3%95%E5%AE%9E%E7%8E%B0)
17+
- [遍历子元素打标识](#%E9%81%8D%E5%8E%86%E5%AD%90%E5%85%83%E7%B4%A0%E6%89%93%E6%A0%87%E8%AF%86)
18+
- [渲染差异](#%E6%B8%B2%E6%9F%93%E5%B7%AE%E5%BC%82)
19+
- [最后](#%E6%9C%80%E5%90%8E)
20+
21+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
22+
123
# MVVM
224

325
MVVM 由以下三个内容组成

Framework/react-en.md

+11
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [React Lifecycle analysis](#react-lifecycle-analysis)
6+
- [The usage advice of Lifecycle methods in React V16](#the-usage-advice-of--lifecycle-methods-in-react-v16)
7+
- [setState](#setstate)
8+
- [Redux Source Code Analysis](#redux-source-code-analysis)
9+
10+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
11+
112
# React Lifecycle analysis
213

314
The Fiber mechanism was introduced in the V16 release. The mechanism affects some of the lifecycle calls to a certain extent and introduces two new APIs to solve the problems.

Framework/react-zh.md

+11
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [React 生命周期分析](#react-%E7%94%9F%E5%91%BD%E5%91%A8%E6%9C%9F%E5%88%86%E6%9E%90)
6+
- [V16 生命周期函数用法建议](#v16-%E7%94%9F%E5%91%BD%E5%91%A8%E6%9C%9F%E5%87%BD%E6%95%B0%E7%94%A8%E6%B3%95%E5%BB%BA%E8%AE%AE)
7+
- [setState](#setstate)
8+
- [Redux 源码分析](#redux-%E6%BA%90%E7%A0%81%E5%88%86%E6%9E%90)
9+
10+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
11+
112
# React 生命周期分析
213

314
在 V16 版本中引入了 Fiber 机制。这个机制一定程度上的影响了部分生命周期的调用,并且也引入了新的 2 个 API 来解决问题。

Framework/vue-en.md

+8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [NextTick principle analysis](#nexttick-principle-analysis)
6+
7+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
8+
19
# NextTick principle analysis
210

311
`nextTick` allows us to defer the callback to be executed after the next DOM update cycle,to get the updated DOM.

Framework/vue-zh.md

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [NextTick 原理分析](#nexttick-%E5%8E%9F%E7%90%86%E5%88%86%E6%9E%90)
6+
- [生命周期分析](#%E7%94%9F%E5%91%BD%E5%91%A8%E6%9C%9F%E5%88%86%E6%9E%90)
7+
8+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
9+
110
# NextTick 原理分析
211

312
`nextTick` 可以让我们在下次 DOM 更新循环结束之后执行延迟回调,用于获得更新后的 DOM。

JS/JS-ch.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
- [深拷贝](#%E6%B7%B1%E6%8B%B7%E8%B4%9D)
2222
- [模块化](#%E6%A8%A1%E5%9D%97%E5%8C%96)
2323
- [CommonJS](#commonjs)
24-
- [ADM](#adm)
24+
- [AMD](#amd)
2525
- [防抖](#%E9%98%B2%E6%8A%96)
2626
- [节流](#%E8%8A%82%E6%B5%81)
2727
- [继承](#%E7%BB%A7%E6%89%BF)

JS/JS-en.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77
- [Converting to Boolean](#converting-to-boolean)
88
- [Objects to Primitive Types](#objects-to-primitive-types)
99
- [Arithmetic Operators](#arithmetic-operators)
10-
- [`==` operator](#operator)
10+
- [`==` operator](#-operator)
1111
- [Comparison Operator](#comparison-operator)
1212
- [Typeof](#typeof)
13-
- [Type Conversion](#type-conversion)
14-
- [Converting to Boolean](#converting-to-boolean)
15-
- [Objects to Primitive Types](#objects-to-primitive-types)
16-
- [Arithmetic Operators](#arithmetic-operators)
17-
- [`==` operator](#operator)
18-
- [Comparison Operator](#comparison-operator)
13+
- [Type Conversion](#type-conversion-1)
14+
- [Converting to Boolean](#converting-to-boolean-1)
15+
- [Objects to Primitive Types](#objects-to-primitive-types-1)
16+
- [Arithmetic Operators](#arithmetic-operators-1)
17+
- [`==` operator](#-operator-1)
18+
- [Comparison Operator](#comparison-operator-1)
1919
- [New](#new)
2020
- [This](#this)
2121
- [Instanceof](#instanceof)
@@ -29,15 +29,15 @@
2929
- [Modularization](#modularization)
3030
- [CommonJS](#commonjs)
3131
- [ADM](#adm)
32-
- [simulation to implement `call` and `apply`](#simulation-to-implement-call-and-apply)
32+
- [simulation to implement `call` and `apply`](#simulation-to-implement---call-and--apply)
3333
- [Promise implementation](#promise-implementation)
3434
- [Generator Implementation](#generator-implementation)
3535
- [Debouncing](#debouncing)
3636
- [Throttle](#throttle)
3737
- [Map、FlapMap and Reduce](#mapflapmap-and-reduce)
3838
- [Async and await](#async-and-await)
3939
- [Proxy](#proxy)
40-
- [Why 0.1 + 0.2 != 0.3](#why-01-02-03)
40+
- [Why 0.1 + 0.2 != 0.3](#why-01--02--03)
4141
- [Regular Expressions](#regular-expressions)
4242
- [Metacharacters](#metacharacters)
4343
- [Flags](#flags)

Network/Network_en.md

+41
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,44 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [UDP](#udp)
6+
- [Message-oriented](#message-oriented)
7+
- [Unreliable](#unreliable)
8+
- [Efficient](#efficient)
9+
- [Transmission mode](#transmission-mode)
10+
- [TCP](#tcp)
11+
- [Header](#header)
12+
- [State machine](#state-machine)
13+
- [Three-way handshake in opening a connection](#three-way-handshake-in-opening-a-connection)
14+
- [Four-handshake of disconnect.](#four-handshake-of-disconnect)
15+
- [ARQ protocol](#arq-protocol)
16+
- [Stop-and-Wait ARQ](#stop-and-wait-arq)
17+
- [Continuous ARQ](#continuous-arq)
18+
- [Cumulative Acknowledgement](#cumulative-acknowledgement)
19+
- [Sliding window](#sliding-window)
20+
- [Zero window](#zero-window)
21+
- [Congestion Control](#congestion-control)
22+
- [Slow-start algorithms](#slow-start-algorithms)
23+
- [Congestion Avoidance algorithms](#congestion-avoidance-algorithms)
24+
- [Fast Retransmit](#fast-retransmit)
25+
- [Fast Recovery (TCP New Reno)](#fast-recovery-tcp-new-reno)
26+
- [HTTP](#http)
27+
- [Difference between POST & GET](#difference-between-post--get)
28+
- [Common Status Code](#common-status-code)
29+
- [HTTPS](#https)
30+
- [TLS](#tls)
31+
- [HTTP/2](#http2)
32+
- [Binary Transport](#binary-transport)
33+
- [MultiPlexing](#multiplexing)
34+
- [Header compression](#header-compression)
35+
- [server push](#server-push)
36+
- [QUIC](#quic)
37+
- [DNS](#dns)
38+
- [What happens when you navigate to an URL](#what-happens-when-you-navigate-to-an-url)
39+
40+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
41+
142
# UDP
243

344
## Message-oriented

Performance/performance-ch.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
- [缓存](#%E7%BC%93%E5%AD%98)
88
- [强缓存](#%E5%BC%BA%E7%BC%93%E5%AD%98)
99
- [协商缓存](#%E5%8D%8F%E5%95%86%E7%BC%93%E5%AD%98)
10-
- [Last-Modified 和 If-Modified-Since](#last-modified-%E5%92%8C-if-modified-since)
11-
- [ETag 和 If-None-Match](#etag-%E5%92%8C-if-none-match)
10+
- [Last-Modified 和 If-Modified-Since](#last-modified-%E5%92%8C-if-modified-since)
11+
- [ETag 和 If-None-Match](#etag-%E5%92%8C-if-none-match)
1212
- [选择合适的缓存策略](#%E9%80%89%E6%8B%A9%E5%90%88%E9%80%82%E7%9A%84%E7%BC%93%E5%AD%98%E7%AD%96%E7%95%A5)
1313
- [使用 HTTP / 2.0](#%E4%BD%BF%E7%94%A8-http--20)
1414
- [预加载](#%E9%A2%84%E5%8A%A0%E8%BD%BD)

README-ZH.md

+19
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,22 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [
6+
Interview Map
7+
](#interview-map)
8+
- [这是一份能让你更好准备下一次面试的图谱](#%E8%BF%99%E6%98%AF%E4%B8%80%E4%BB%BD%E8%83%BD%E8%AE%A9%E4%BD%A0%E6%9B%B4%E5%A5%BD%E5%87%86%E5%A4%87%E4%B8%8B%E4%B8%80%E6%AC%A1%E9%9D%A2%E8%AF%95%E7%9A%84%E5%9B%BE%E8%B0%B1)
9+
- [前言](#%E5%89%8D%E8%A8%80)
10+
- [大纲](#%E5%A4%A7%E7%BA%B2)
11+
- [贡献](#%E8%B4%A1%E7%8C%AE)
12+
- [Todo](#todo)
13+
- [阅读](#%E9%98%85%E8%AF%BB)
14+
- [交流分享](#%E4%BA%A4%E6%B5%81%E5%88%86%E4%BA%AB)
15+
- [支持我们](#%E6%94%AF%E6%8C%81%E6%88%91%E4%BB%AC)
16+
- [协议](#%E5%8D%8F%E8%AE%AE)
17+
18+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
19+
120
<img align="center" src='./InterviewMap.png' />
221

322
<h1 align="center">

README.md

+19
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,22 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [
6+
Interview Map
7+
](#interview-map)
8+
- [This is a map that can help you make a better preparation for the next interview](#this-is-a-map-that-can-help-you-make-a-better-preparation-for-the-next-interview)
9+
- [Foreword](#foreword)
10+
- [Outline](#outline)
11+
- [Contributing](#contributing)
12+
- [Todo](#todo)
13+
- [Reading](#reading)
14+
- [Communicate and share](#communicate-and-share)
15+
- [Support us](#support-us)
16+
- [License](#license)
17+
18+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
19+
120

221

322
<img align="center" src='./InterviewMap.png' />

Safety/safety-cn.md

-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
- [Token](#token)
1515
- [密码安全](#%E5%AF%86%E7%A0%81%E5%AE%89%E5%85%A8)
1616
- [加盐](#%E5%8A%A0%E7%9B%90)
17-
- [前端加密](#%E5%89%8D%E7%AB%AF%E5%8A%A0%E5%AF%86)
1817

1918
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
2019

Safety/safety-en.md

+19
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,22 @@
1+
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2+
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3+
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4+
5+
- [XSS](#xss)
6+
- [How to attack](#how-to-attack)
7+
- [How to defend](#how-to-defend)
8+
- [CSP](#csp)
9+
- [CSRF](#csrf)
10+
- [How to attack](#how-to-attack-1)
11+
- [How to defend](#how-to-defend-1)
12+
- [SameSite](#samesite)
13+
- [Verify Referer](#verify--referer)
14+
- [Token](#token)
15+
- [Password security](#password-security)
16+
- [Add salt](#add-salt)
17+
18+
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
19+
120
## XSS
221

322
> **Cross-site scripting**(Cross-site scripting in English, often abbreviated as XSS)is one kind of security vulnerabilities attack of web applications , and is a kind of [code input](https://www.wikiwand.com/zh-hans/%E4%BB%A3%E7%A2%BC%E6%B3%A8%E5%85%A5)It allows malicious users to input code into web pages, and other users are affected when they browse web pages. Such attacks often include HTML and consumer-side scripting languages.

0 commit comments

Comments
 (0)