Skip to content

Commit b70dd8e

Browse files
merging all conflicts
2 parents 35e158f + 2c7798d commit b70dd8e

File tree

340 files changed

+13132
-2134
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

340 files changed

+13132
-2134
lines changed

.eslintrc

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,36 @@
22
"root": true,
33
"extends": "next/core-web-vitals",
44
"parser": "@typescript-eslint/parser",
5-
"plugins": ["@typescript-eslint", "eslint-plugin-react-compiler"],
5+
"plugins": ["@typescript-eslint", "eslint-plugin-react-compiler", "local-rules"],
66
"rules": {
77
"no-unused-vars": "off",
88
"@typescript-eslint/no-unused-vars": ["error", {"varsIgnorePattern": "^_"}],
99
"react-hooks/exhaustive-deps": "error",
1010
"react/no-unknown-property": ["error", {"ignore": ["meta"]}],
11-
"react-compiler/react-compiler": "error"
11+
"react-compiler/react-compiler": "error",
12+
"local-rules/lint-markdown-code-blocks": "error"
1213
},
1314
"env": {
1415
"node": true,
1516
"commonjs": true,
1617
"browser": true,
1718
"es6": true
18-
}
19+
},
20+
"overrides": [
21+
{
22+
"files": ["src/content/**/*.md"],
23+
"parser": "./eslint-local-rules/parser",
24+
"parserOptions": {
25+
"sourceType": "module"
26+
},
27+
"rules": {
28+
"no-unused-vars": "off",
29+
"@typescript-eslint/no-unused-vars": "off",
30+
"react-hooks/exhaustive-deps": "off",
31+
"react/no-unknown-property": "off",
32+
"react-compiler/react-compiler": "off",
33+
"local-rules/lint-markdown-code-blocks": "error"
34+
}
35+
}
36+
]
1937
}

.github/workflows/analyze_comment.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,11 @@ on:
66
types:
77
- completed
88

9-
permissions: {}
10-
9+
permissions:
10+
contents: read
11+
issues: write
12+
pull-requests: write
13+
1114
jobs:
1215
comment:
1316
runs-on: ubuntu-latest

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
22

33
# dependencies
4-
/node_modules
4+
node_modules
55
/.pnp
66
.pnp.js
77

colors.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
/**
2+
* Copyright (c) Meta Platforms, Inc. and affiliates.
3+
*
4+
* This source code is licensed under the MIT license found in the
5+
* LICENSE file in the root directory of this source tree.
6+
*/
7+
18
/*
29
* Copyright (c) Facebook, Inc. and its affiliates.
310
*/
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
```jsx
2+
import {useState} from 'react';
3+
function Counter() {
4+
const [count, setCount] = useState(0);
5+
setCount(count + 1);
6+
return <div>{count}</div>;
7+
}
8+
```
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
```jsx title="Counter" {expectedErrors: {'react-compiler': [99]}} {expectedErrors: {'react-compiler': [2]}}
2+
import {useState} from 'react';
3+
function Counter() {
4+
const [count, setCount] = useState(0);
5+
setCount(count + 1);
6+
return <div>{count}</div>;
7+
}
8+
```
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
```jsx {expectedErrors: {'react-compiler': 'invalid'}}
2+
import {useState} from 'react';
3+
function Counter() {
4+
const [count, setCount] = useState(0);
5+
setCount(count + 1);
6+
return <div>{count}</div>;
7+
}
8+
```
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
```bash
2+
setCount()
3+
```
4+
5+
```txt
6+
import {useState} from 'react';
7+
```
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
```jsx {expectedErrors: {'react-compiler': [3]}}
2+
function Hello() {
3+
return <h1>Hello</h1>;
4+
}
5+
```
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
```jsx {expectedErrors: {'react-compiler': [4]}}
2+
import {useState} from 'react';
3+
function Counter() {
4+
const [count, setCount] = useState(0);
5+
setCount(count + 1);
6+
return <div>{count}</div>;
7+
}
8+
```

0 commit comments

Comments
 (0)