Skip to content

Commit

Permalink
chore: add missing images (#16017)
Browse files Browse the repository at this point in the history
* fix: add missing images

* chore: move images to asset folder

* chore: update path
  • Loading branch information
amareshsm committed Jun 22, 2022
1 parent 910f741 commit 48904fb
Show file tree
Hide file tree
Showing 27 changed files with 25 additions and 25 deletions.
2 changes: 1 addition & 1 deletion docs/src/developer-guide/architecture/index.md
Expand Up @@ -9,7 +9,7 @@ eleventyNavigation:
order: 1
---

<center><img alt="dependency graph" src="dependency.svg"></center>
<center><img alt="dependency graph" src="../../assets/images/architecture/dependency.svg"></center>

At a high level, there are a few key parts to ESLint:

Expand Down
48 changes: 24 additions & 24 deletions docs/src/developer-guide/code-path-analysis.md
Expand Up @@ -16,7 +16,7 @@ if (a && b) {
bar();
```

![Code Path Example](./code-path-analysis/helo.svg)
![Code Path Example](../assets/images/code-path-analysis/helo.svg)

## Objects

Expand Down Expand Up @@ -145,17 +145,17 @@ bar();

1. First, the analysis advances to the end of loop.

![Loop Event's Example 1](./code-path-analysis/loop-event-example-while-1.svg)
![Loop Event's Example 1](../assets/images/code-path-analysis/loop-event-example-while-1.svg)

2. Second, it creates the looping path.
At this time, the next segment has existed already, so the `onCodePathSegmentStart` event is not fired.
It fires `onCodePathSegmentLoop` instead.

![Loop Event's Example 2](./code-path-analysis/loop-event-example-while-2.svg)
![Loop Event's Example 2](../assets/images/code-path-analysis/loop-event-example-while-2.svg)

3. Last, it advances to the end.

![Loop Event's Example 3](./code-path-analysis/loop-event-example-while-3.svg)
![Loop Event's Example 3](../assets/images/code-path-analysis/loop-event-example-while-3.svg)

For example 2:

Expand All @@ -170,29 +170,29 @@ bar();
First, the analysis advances to `ForStatement.update`.
The `update` segment is hovered at first.

![Loop Event's Example 1](./code-path-analysis/loop-event-example-for-1.svg)
![Loop Event's Example 1](../assets/images/code-path-analysis/loop-event-example-for-1.svg)

2. Second, it advances to `ForStatement.body`.
Of course the `body` segment is preceded by the `test` segment.
It keeps the `update` segment hovering.

![Loop Event's Example 2](./code-path-analysis/loop-event-example-for-2.svg)
![Loop Event's Example 2](../assets/images/code-path-analysis/loop-event-example-for-2.svg)

3. Third, it creates the looping path from `body` segment to `update` segment.
At this time, the next segment has existed already, so the `onCodePathSegmentStart` event is not fired.
It fires `onCodePathSegmentLoop` instead.

![Loop Event's Example 3](./code-path-analysis/loop-event-example-for-3.svg)
![Loop Event's Example 3](../assets/images/code-path-analysis/loop-event-example-for-3.svg)

4. Fourth, also it creates the looping path from `update` segment to `test` segment.
At this time, the next segment has existed already, so the `onCodePathSegmentStart` event is not fired.
It fires `onCodePathSegmentLoop` instead.

![Loop Event's Example 4](./code-path-analysis/loop-event-example-for-4.svg)
![Loop Event's Example 4](../assets/images/code-path-analysis/loop-event-example-for-4.svg)

5. Last, it advances to the end.

![Loop Event's Example 5](./code-path-analysis/loop-event-example-for-5.svg)
![Loop Event's Example 5](../assets/images/code-path-analysis/loop-event-example-for-5.svg)

## Usage Examples

Expand Down Expand Up @@ -338,7 +338,7 @@ See Also:
console.log("Hello world!");
```

![Hello World](./code-path-analysis/example-hello-world.svg)
![Hello World](../assets/images/code-path-analysis/example-hello-world.svg)

### `IfStatement`

Expand All @@ -350,7 +350,7 @@ if (a) {
}
```

![`IfStatement`](./code-path-analysis/example-ifstatement.svg)
![`IfStatement`](../assets/images/code-path-analysis/example-ifstatement.svg)

### `IfStatement` (chain)

Expand All @@ -364,7 +364,7 @@ if (a) {
}
```

![`IfStatement` (chain)](./code-path-analysis/example-ifstatement-chain.svg)
![`IfStatement` (chain)](../assets/images/code-path-analysis/example-ifstatement-chain.svg)

### `SwitchStatement`

Expand All @@ -385,7 +385,7 @@ switch (a) {
}
```

![`SwitchStatement`](./code-path-analysis/example-switchstatement.svg)
![`SwitchStatement`](../assets/images/code-path-analysis/example-switchstatement.svg)

### `SwitchStatement` (has `default`)

Expand All @@ -410,7 +410,7 @@ switch (a) {
}
```

![`SwitchStatement` (has `default`)](./code-path-analysis/example-switchstatement-has-default.svg)
![`SwitchStatement` (has `default`)](../assets/images/code-path-analysis/example-switchstatement-has-default.svg)

### `TryStatement` (try-catch)

Expand All @@ -433,7 +433,7 @@ It creates the paths from `try` block to `catch` block at:
* The first throwable node (e.g. a function call) in the `try` block.
* The end of the `try` block.

![`TryStatement` (try-catch)](./code-path-analysis/example-trystatement-try-catch.svg)
![`TryStatement` (try-catch)](../assets/images/code-path-analysis/example-trystatement-try-catch.svg)

### `TryStatement` (try-finally)

Expand All @@ -451,7 +451,7 @@ If there is not `catch` block, `finally` block has two current segments.
At this time, `CodePath.currentSegments.length` is `2`.
One is the normal path, and another is the leaving path (`throw` or `return`).

![`TryStatement` (try-finally)](./code-path-analysis/example-trystatement-try-finally.svg)
![`TryStatement` (try-finally)](../assets/images/code-path-analysis/example-trystatement-try-finally.svg)

### `TryStatement` (try-catch-finally)

Expand All @@ -467,7 +467,7 @@ try {
last();
```

![`TryStatement` (try-catch-finally)](./code-path-analysis/example-trystatement-try-catch-finally.svg)
![`TryStatement` (try-catch-finally)](../assets/images/code-path-analysis/example-trystatement-try-catch-finally.svg)

### `WhileStatement`

Expand All @@ -481,7 +481,7 @@ while (a) {
}
```

![`WhileStatement`](./code-path-analysis/example-whilestatement.svg)
![`WhileStatement`](../assets/images/code-path-analysis/example-whilestatement.svg)

### `DoWhileStatement`

Expand All @@ -492,7 +492,7 @@ do {
} while (a);
```

![`DoWhileStatement`](./code-path-analysis/example-dowhilestatement.svg)
![`DoWhileStatement`](../assets/images/code-path-analysis/example-dowhilestatement.svg)

### `ForStatement`

Expand All @@ -506,7 +506,7 @@ for (let i = 0; i < 10; ++i) {
}
```

![`ForStatement`](./code-path-analysis/example-forstatement.svg)
![`ForStatement`](../assets/images/code-path-analysis/example-forstatement.svg)

### `ForStatement` (for ever)

Expand All @@ -517,7 +517,7 @@ for (;;) {
bar();
```

![`ForStatement` (for ever)](./code-path-analysis/example-forstatement-for-ever.svg)
![`ForStatement` (for ever)](../assets/images/code-path-analysis/example-forstatement-for-ever.svg)

### `ForInStatement`

Expand All @@ -527,7 +527,7 @@ for (let key in obj) {
}
```

![`ForInStatement`](./code-path-analysis/example-forinstatement.svg)
![`ForInStatement`](../assets/images/code-path-analysis/example-forinstatement.svg)

### When there is a function

Expand All @@ -546,8 +546,8 @@ It creates two code paths.

* The global's

![When there is a function](./code-path-analysis/example-when-there-is-a-function-g.svg)
![When there is a function](../assets/images/code-path-analysis/example-when-there-is-a-function-g.svg)

* The function's

![When there is a function](./code-path-analysis/example-when-there-is-a-function-f.svg)
![When there is a function](../assets/images/code-path-analysis/example-when-there-is-a-function-f.svg)

0 comments on commit 48904fb

Please sign in to comment.