Add `noImplicitOverride`

`noImplicitOverride` guarantees type safety when overriding a class method. This also improves refactoring behavior.

The primary motivation for `noImplicitOverride` is for using with Lit elements where overriding methods is important.

Bug: 1402569
Change-Id: Ia095c38a6d1fc160f9b08c350d6f7248daab38a4
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/4443322
Reviewed-by: Jack Franklin <[email protected]>
Commit-Queue: Randolf Jung <[email protected]>
diff --git a/front_end/panels/sources/WatchExpressionsSidebarPane.ts b/front_end/panels/sources/WatchExpressionsSidebarPane.ts
index 447aa7c..2f94d31 100644
--- a/front_end/panels/sources/WatchExpressionsSidebarPane.ts
+++ b/front_end/panels/sources/WatchExpressionsSidebarPane.ts
@@ -142,7 +142,7 @@
     return [this.addButton, this.refreshButton];
   }
 
-  focus(): void {
+  override focus(): void {
     if (this.hasFocus()) {
       return;
     }
@@ -173,7 +173,7 @@
     this.createWatchExpression(null).startEditing();
   }
 
-  async doUpdate(): Promise<void> {
+  override async doUpdate(): Promise<void> {
     this.linkifier.reset();
     this.contentElement.removeChildren();
     this.treeOutline.removeChildren();
@@ -286,7 +286,7 @@
 
     contextMenu.debugSection().appendAction('sources.add-to-watch');
   }
-  wasShown(): void {
+  override wasShown(): void {
     super.wasShown();
     this.treeOutline.registerCSSFiles([watchExpressionsSidebarPaneStyles]);
     this.registerCSSFiles([watchExpressionsSidebarPaneStyles, objectValueStyles]);