Skip to content

Commit dbf8b8f

Browse files
chore(ci): synchronize to a081bbe (#2874)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 929b7ea commit dbf8b8f

File tree

11 files changed

+216
-107
lines changed

11 files changed

+216
-107
lines changed

Cargo.lock

Lines changed: 70 additions & 70 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -16,38 +16,38 @@ path = "codegen/src/lib.rs"
1616
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
1717
[dependencies]
1818
anyhow = "1.0.98"
19-
biome_analyze = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3", features = [
19+
biome_analyze = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1", features = [
2020
"schema",
2121
] }
22-
biome_cli = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
23-
biome_configuration = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3", features = [
22+
biome_cli = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
23+
biome_configuration = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1", features = [
2424
"schema",
2525
] }
26-
biome_console = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
27-
biome_css_analyze = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
28-
biome_css_parser = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
29-
biome_css_syntax = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
30-
biome_deserialize = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
31-
biome_diagnostics = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
32-
biome_flags = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
33-
biome_formatter = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
34-
biome_fs = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
35-
biome_graphql_analyze = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
36-
biome_graphql_parser = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
37-
biome_graphql_syntax = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
38-
biome_js_analyze = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
39-
biome_js_formatter = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
40-
biome_js_parser = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
41-
biome_js_syntax = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
42-
biome_json_analyze = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
43-
biome_json_factory = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
44-
biome_json_formatter = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
45-
biome_json_parser = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
46-
biome_json_syntax = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
47-
biome_rowan = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
48-
biome_service = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
49-
biome_string_case = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
50-
biome_text_edit = { git = "https://github.com/biomejs/biome.git", rev = "3f436b84bb62320c16c1ca1ac5b419e4d9abefb3" }
26+
biome_console = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
27+
biome_css_analyze = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
28+
biome_css_parser = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
29+
biome_css_syntax = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
30+
biome_deserialize = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
31+
biome_diagnostics = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
32+
biome_flags = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
33+
biome_formatter = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
34+
biome_fs = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
35+
biome_graphql_analyze = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
36+
biome_graphql_parser = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
37+
biome_graphql_syntax = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
38+
biome_js_analyze = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
39+
biome_js_formatter = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
40+
biome_js_parser = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
41+
biome_js_syntax = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
42+
biome_json_analyze = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
43+
biome_json_factory = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
44+
biome_json_formatter = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
45+
biome_json_parser = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
46+
biome_json_syntax = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
47+
biome_rowan = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
48+
biome_service = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
49+
biome_string_case = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
50+
biome_text_edit = { git = "https://github.com/biomejs/biome.git", rev = "a081bbef37a4b329ace1cb0eb88c36f6c6162af1" }
5151
bpaf = { version = "0.9.20", features = ["docgen"] }
5252
# Needed to fix some weird dependency
5353
lock_api = "0.4.13"

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"@astrojs/rss": "4.0.12",
3434
"@astrojs/starlight": "0.35.2",
3535
"@biomejs/biome": "2.1.4",
36-
"@biomejs/wasm-web": "https://pkg.pr.new/biomejs/biome/@biomejs/wasm-web@3f436b8",
36+
"@biomejs/wasm-web": "https://pkg.pr.new/biomejs/biome/@biomejs/wasm-web@a081bbe",
3737
"@codemirror/lang-css": "6.3.1",
3838
"@codemirror/lang-html": "6.4.9",
3939
"@codemirror/lang-javascript": "6.2.4",

pnpm-lock.yaml

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

redirects.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ export default {
129129
'/linter/rules/noNegationElse': '/linter/rules/no-negation-else',
130130
'/linter/rules/noNestedComponentDefinitions': '/linter/rules/no-nested-component-definitions',
131131
'/linter/rules/noNestedTernary': '/linter/rules/no-nested-ternary',
132+
'/linter/rules/noNextAsyncClientComponent': '/linter/rules/no-next-async-client-component',
132133
'/linter/rules/noNodejsModules': '/linter/rules/no-nodejs-modules',
133134
'/linter/rules/noNonNullAssertedOptionalChain': '/linter/rules/no-non-null-asserted-optional-chain',
134135
'/linter/rules/noNonNullAssertion': '/linter/rules/no-non-null-assertion',

src/components/generated/linter/NumberOfRules.astro

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/content/docs/linter/domains.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ Enabled when the following dependencies are declared:
4444
Rules that belong to the domain:
4545
- [useExhaustiveDependencies](/linter/rules/use-exhaustive-dependencies) (recommended)
4646
- [useHookAtTopLevel](/linter/rules/use-hook-at-top-level) (recommended)
47+
- [noNextAsyncClientComponent](/linter/rules/no-next-async-client-component)
4748
- [noUnwantedPolyfillio](/linter/rules/no-unwanted-polyfillio) (recommended)
4849
- [useGoogleFontPreconnect](/linter/rules/use-google-font-preconnect) (recommended)
4950
- [noImgElement](/linter/rules/no-img-element) (recommended)

src/content/docs/linter/javascript/rules.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,7 @@ Below the list of rules supported by Biome, divided by group. Here's a legend of
162162
| [noMagicNumbers](/linter/rules/no-magic-numbers) | Reports usage of "magic numbers" — numbers used directly instead of being assigned to named constants. | |
163163
| [noMisusedPromises](/linter/rules/no-misused-promises) | Disallow Promises to be used in places where they are almost certainly a | <span class='inline-icon' title="The rule has an unsafe fix" ><Icon name="warning" label="The rule has an unsafe fix" size="1.2rem" /></span> |
164164
| [noNestedComponentDefinitions](/linter/rules/no-nested-component-definitions) | Disallows defining React components inside other components. | |
165+
| [noNextAsyncClientComponent](/linter/rules/no-next-async-client-component) | Prevent client components from being async functions. | <span class='inline-icon' title="This rule is not released yet"><Icon name="moon" label="This rule is not released yet" size="1.2rem" /></span> |
165166
| [noNonNullAssertedOptionalChain](/linter/rules/no-non-null-asserted-optional-chain) | Disallow non-null assertions after optional chaining expressions. | |
166167
| [noNoninteractiveElementInteractions](/linter/rules/no-noninteractive-element-interactions) | Disallow use event handlers on non-interactive elements. | |
167168
| [noProcessGlobal](/linter/rules/no-process-global) | Disallow the use of `process` global. | <span class='inline-icon' title='The rule has a safe fix.'><Icon name="seti:config" label="The rule has a safe fix" size="1.2rem" /></span> |
Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
---
2+
# Don't modify this file manually. This file is auto generated from source, and you will lose your changes next time the website is built.
3+
# Head to the `biomejs/biome` repository, and modify the source code in there.
4+
5+
title: noNextAsyncClientComponent
6+
description: Learn more about noNextAsyncClientComponent
7+
---
8+
import { Tabs, TabItem } from '@astrojs/starlight/components';
9+
10+
<Tabs>
11+
<TabItem label="JavaScript (and super languages)" icon="seti:javascript">
12+
:::note
13+
This rule has been implemented but not released yet. It will be available in the next release.
14+
:::
15+
:::caution
16+
This rule is part of the [nursery](/linter/#nursery) group. This means that it is experimental and the behavior can change at any time.
17+
:::
18+
## Summary
19+
- Diagnostic Category: [`lint/nursery/noNextAsyncClientComponent`](/reference/diagnostics#diagnostic-category)
20+
- This rule doesn't have a fix.
21+
- The default severity of this rule is [**warning**](/reference/diagnostics#warning).
22+
- This rule belongs to the following domains:
23+
- [`next`](/linter/domains#next)
24+
- Sources:
25+
- Same as [`@next/no-async-client-component`](https://nextjs.org/docs/messages/no-async-client-component)
26+
27+
## Description
28+
Prevent client components from being async functions.
29+
30+
This rule prevents the use of async functions for client components in Next.js applications.
31+
Client components marked with "use client" directive should not be async as this can cause
32+
hydration mismatches, break component rendering lifecycle, and lead to unexpected behavior
33+
with React's concurrent features.
34+
35+
## Examples
36+
37+
### Invalid
38+
39+
```jsx
40+
"use client";
41+
42+
export default async function MyComponent() {
43+
return <div>Hello</div>;
44+
}
45+
```
46+
47+
<pre class="language-text"><code class="language-text">code-block.jsx:3:16 <a href="https://biomejs.dev/linter/rules/no-next-async-client-component">lint/nursery/noNextAsyncClientComponent</a> ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━<br /><br /> <strong><span style="color: Orange;">⚠</span></strong> <span style="color: Orange;">The component </span><span style="color: Orange;"><strong>MyComponent</strong></span><span style="color: Orange;"> is an async client component, which is not allowed.</span><br /> <br /> <strong>1 │ </strong>&quot;use client&quot;;<br /> <strong>2 │ </strong><br /> <strong><span style="color: Tomato;">&gt;</span></strong> <strong>3 │ </strong>export default async function MyComponent() &#123;<br /> <strong> │ </strong> <strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><strong><span style="color: Tomato;">^</span></strong><br /> <strong><span style="color: Tomato;">&gt;</span></strong> <strong>4 │ </strong> return &lt;div&gt;Hello&lt;/div&gt;;<br /> <strong><span style="color: Tomato;">&gt;</span></strong> <strong>5 │ </strong>&#125;<br /> <strong> │ </strong><strong><span style="color: Tomato;">^</span></strong><br /> <strong>6 │ </strong><br /> <br /> <strong><span style="color: lightgreen;">ℹ</span></strong> <span style="color: lightgreen;">Client components with &quot;use client&quot; directive should not be async functions as this can cause hydration mismatches and break React's rendering lifecycle.</span><br /> <br /> <strong><span style="color: lightgreen;">ℹ</span></strong> <span style="color: lightgreen;">Consider using useEffect for async operations inside the component, or remove the &quot;use client&quot; directive if this should be a server component.</span><br /> <br /></code></pre>
48+
49+
### Valid
50+
51+
```jsx
52+
"use client";
53+
54+
export default function MyComponent() {
55+
return <div>Hello</div>;
56+
}
57+
```
58+
59+
```jsx
60+
// No "use client" directive - server component can be async
61+
export default async function ServerComponent() {
62+
const data = await fetch('/api/data');
63+
return <div>{data}</div>;
64+
}
65+
```
66+
67+
## How to configure
68+
```json title="biome.json"
69+
{
70+
"linter": {
71+
"rules": {
72+
"nursery": {
73+
"noNextAsyncClientComponent": "error"
74+
}
75+
}
76+
}
77+
}
78+
79+
```
80+
## Related links
81+
82+
- [Disable a rule](/linter/#disable-a-rule)
83+
- [Configure the code fix](/linter#configure-the-code-fix)
84+
- [Rule options](/linter/#rule-options)
85+
86+
</TabItem>
87+
</Tabs>
88+

0 commit comments

Comments
 (0)