From 8049e5dca97e9d483323198815b31e7a234ed6ce Mon Sep 17 00:00:00 2001 From: Joseph Izang Date: Fri, 28 Apr 2023 11:53:41 +0100 Subject: [PATCH] fix comments from @bunsenstraat --- apps/solhint/src/app/App.tsx | 18 +++++------------- apps/solhint/src/app/SolhintPluginClient.ts | 7 +------ apps/solhint/src/profile.json | 2 +- 3 files changed, 7 insertions(+), 20 deletions(-) diff --git a/apps/solhint/src/app/App.tsx b/apps/solhint/src/app/App.tsx index 9acc0b4ce0..ac1eae48b3 100644 --- a/apps/solhint/src/app/App.tsx +++ b/apps/solhint/src/app/App.tsx @@ -1,16 +1,8 @@ -import React, { useEffect, useState } from "react" -import { SolHint } from "./SolhintPluginClient" +import React, { useEffect, useState } from "react"; +import { SolHint } from "./SolhintPluginClient"; - -const client = new SolHint() +const client = new SolHint(); export default function App() { - - return ( - <> -
- -
- - ) -} \ No newline at end of file + return <>; +} diff --git a/apps/solhint/src/app/SolhintPluginClient.ts b/apps/solhint/src/app/SolhintPluginClient.ts index 35c8d8f267..943e0ce899 100644 --- a/apps/solhint/src/app/SolhintPluginClient.ts +++ b/apps/solhint/src/app/SolhintPluginClient.ts @@ -1,8 +1,7 @@ import { PluginClient } from '@remixproject/plugin' import { createClient } from '@remixproject/plugin-webview' import EventEmitter from 'events' -import { processStr } from 'solhint' -import { applyExtends } from 'solhint/lib/config/config-file' +import { applyExtends, processStr } from 'solhint' import bestPractises from 'solhint/lib/rules/best-practises' import naming from 'solhint/lib/rules/naming' import order from 'solhint/lib/rules/order' @@ -30,15 +29,11 @@ const Config = `{ }` export class SolHint extends PluginClient { - mdFile: string - eventEmitter: EventEmitter triggerLinter: boolean constructor() { super() - this.eventEmitter = new EventEmitter() this.methods = ['lintContract', 'lintOnCompilation', 'lintContractCustomAction'] createClient(this) - this.mdFile = '' this.onload().then(async () => { await this.lintOnCompilation() }) diff --git a/apps/solhint/src/profile.json b/apps/solhint/src/profile.json index 6e762ea53f..2964511f3b 100644 --- a/apps/solhint/src/profile.json +++ b/apps/solhint/src/profile.json @@ -11,7 +11,7 @@ ], "kind": "none", "icon": "https://raw.githubusercontent.com/protofire/solhint/master/solhint-icon.png", - "location": "sidePanel", + "location": "hiddenPanel", "url": "", "documentation": "https://remix-plugins.readthedocs.io/en/latest/", "repo": "https://github.com/ethereum/remix-project",