Closed Bug 1607506 Opened 6 years ago Closed 5 years ago

Experiment adding basic TypeScript annotations

Categories

(Remote Protocol :: Agent, enhancement, P3)

enhancement

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1713640

People

(Reporter: ato, Unassigned)

Details

We should explore annotating the remote debugging protocol JavaScript code with TypeScript to increase safety. We have had a series of bugs that could’ve been prevented with a more rigorous type system.

TypeScript is a so-called gradual type system which means we don’t have to adopt it wholesale for the entire code base.

The new performance backend in DevTools already uses TypeScript in-tree, although it is not yet hooked up to any linting tasks, and the TypeScript linter must be run manually:
https://searchfox.org/mozilla-central/source/devtools/client/performance-new

We can set up a manual source-task linting task for our own purposes and hook it up to ./mach remote lint or some such sub-task.

Priority: -- → P3

We have a more detailed bug filed for this as bug 1713640.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.