DeepSource
Dashboard Resources Pricing Discover Directory Log in

Run your first analysis.

Find thousands of code security and quality issues in your codebase, before they end up in production.

Start now
All analyzers JavaScript
JavaScript

JavaScript

By DeepSource

Use Analyzer
Docs
Discuss
Race condition in compound assignment JS-0040
Bug risk

When writing asynchronous code, it is possible to create subtle race condition bugs. Consider the following example:

Null comparisons without type-checking operators may not work as intended JS-0059
Bug risk
Autofix

Comparing to null without a type-checking operator (=== or !==), can have unintended results as the comparison will evaluate to true when comparing to not just a null, but also an undefined value.

Inconsistent class literals JS-0298
Bug risk
Autofix

When writing TypeScript applications, it's safe to store literal values on classes using fields with the readonly modifier to prevent them from being reassigned.

Should not use Arrow functions JS-0774
Bug risk

Arrow functions should not be used in computed properties because they are unable to access other properties (using this.property) of the same object. Accidental usage can thus lead to bugs.

Should not use .on() JS-0800
Bug risk

Avoid using .on() in favour of component's lifecycle hooks. The order of execution for on() is not deterministic.