Turn on noUnusedLocals, noImplicitReturns, importsNotUsedAsValues: error, and isolatedModules (#2777)

This commit is contained in:
Sebastian Malton authored and GitHub committed 2021-05-19 12:11:54 -04:00
1 parent 489cef9595
commit 5ed4537979
287 files changed
+704 -628

No files matched your search

+3 -1
View File
@@ -19,7 +19,7 @@
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
import Url from "url-parse";
import type Url from "url-parse";
export enum RoutingErrorType {
INVALID_PROTOCOL = "invalid-protocol",
@@ -52,6 +52,8 @@ export class RoutingError extends Error {
return "no extension ID";
case RoutingErrorType.MISSING_EXTENSION:
return "extension not found";
default:
return `unknown error: ${this.type}`;
}
}
}
+3 -3
View File
@@ -24,12 +24,12 @@ import { countBy } from "lodash";
import { Singleton } from "../utils";
import { pathToRegexp } from "path-to-regexp";
import logger from "../../main/logger";
import Url from "url-parse";
import type Url from "url-parse";
import { RoutingError, RoutingErrorType } from "./error";
import { ExtensionsStore } from "../../extensions/extensions-store";
import { ExtensionLoader } from "../../extensions/extension-loader";
import { LensExtension } from "../../extensions/lens-extension";
import { RouteHandler, RouteParams } from "../../extensions/registries/protocol-handler-registry";
import type { LensExtension } from "../../extensions/lens-extension";
import type { RouteHandler, RouteParams } from "../../extensions/registries/protocol-handler-registry";
// IPC channel for protocol actions. Main broadcasts the open-url events to this channel.
export const ProtocolHandlerIpcPrefix = "protocol-handler";