Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const source = `https://github.com/oxc-project/oxc/blob/${ data }/crates/oxc_lin

### What it does

Disallow unused labels
Disallow unused labels.

### Why is this bad?

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,26 +39,24 @@ await { then() {} };
// this is not a Promise - it's a function that returns a Promise
declare const getPromise: () => Promise<string>;
await getPromise;
await getPromise;
```

Examples of **correct** code for this rule:

```
await Promise.resolve("value");
await Promise.resolve('value');
await Promise.reject(new Error());

// Promise-like values
await {
then(onfulfilled, onrejected) {
onfulfilled("value");
onfulfilled('value');
},
};

// this is a Promise - produced by calling a function
declare const getPromise: () => Promise<string>;
await getPromise();
await getPromise();
```

## How to use
Expand Down
2 changes: 1 addition & 1 deletion src/docs/guide/usage/linter/rules/version.data.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export default {
load() {
return "8a1cbbdbec47fdf9ea1f7099c3dfd83bd52f3c82";
return "27254963aab6762e5dedc6ddf510ab0c60339b54";
},
};