Skip to content
Merged
Changes from 1 commit
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
3 changes: 3 additions & 0 deletions crates/oxc_linter/src/rules/eslint/no_throw_literal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ declare_oxc_lint!(
///
/// Disallows throwing literals or non-Error objects as exceptions.
///
/// WARNING: This rule has been deprecated, please instead use [typescript/only-throw-error](https://oxc.rs/docs/guide/usage/linter/rules/typescript/only-throw-error.html).
/// The typescript rule is more reliable than the Javascript version, as it has less false positive, and can catch more cases.
Comment thread
camc314 marked this conversation as resolved.
Outdated
///
Comment on lines +25 to +28

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this missing the closing :::?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep you're right - my fault

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2026-02-21 at 18 29 32

oops

/// ### Why is this bad?
///
/// It is considered good practice to only throw the Error object itself or an object using
Expand Down
Loading