From 134796a22f5c4a7e75b2af6a6318a6bbdf63e77a Mon Sep 17 00:00:00 2001 From: Matt Cowley Date: Tue, 28 Jan 2025 21:38:29 +0000 Subject: [PATCH] Misc. dev meta cleanup (#229) * Remove CSS module types * Update process.env types * Remove legacy Twitch developer rig JSON * Remove legacy ESLint JSON * Remove unused ts-expect-error from ESLint config --- .eslintrc.json | 25 ------------ Alveus Ambassadors.json | 87 ----------------------------------------- eslint.config.mjs | 1 - src/react-app-env.d.ts | 24 ++++-------- 4 files changed, 8 insertions(+), 129 deletions(-) delete mode 100644 .eslintrc.json delete mode 100644 Alveus Ambassadors.json diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 5cdc888b..00000000 --- a/.eslintrc.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "parser": "@typescript-eslint/parser", - "extends": [ - "plugin:@typescript-eslint/recommended", - "plugin:react/recommended", - "prettier" - ], - "parserOptions": { - "ecmaVersion": 2021, - "sourceType": "module", - "ecmaFeatures": { - "jsx": true - } - }, - "settings": { - "react": { - "version": "detect" - } - }, - "rules": { - "@typescript-eslint/no-explicit-any": "off", - "react/jsx-uses-react": "off", - "react/react-in-jsx-scope": "off" - } -} diff --git a/Alveus Ambassadors.json b/Alveus Ambassadors.json deleted file mode 100644 index 3c287fbd..00000000 --- a/Alveus Ambassadors.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "allowHttpBackend": false, - "backendCommand": "", - "backendFolderName": "", - "certificateExceptions": [], - "extensionViews": [ - { - "channelId": "117413622", - "configurationAnchor": "panel", - "displayChannelName": "abdullahmorrison", - "features": { - "isBitsEnabled": false, - "isChatEnabled": true, - "isSubscriptionStatusAvailable": false - }, - "frameSize": { - "width": 1280, - "height": 720 - }, - "id": "1", - "isPopout": false, - "label": "Panel", - "linked": false, - "linkedUserId": "", - "orientation": "Portrait", - "type": "panel", - "viewerType": "Broadcaster" - } - ], - "manifest": { - "anchor": "panel", - "assetUrls": [], - "authorName": "Abdullah Morrison", - "bitsEnabled": false, - "canInstall": true, - "configUrl": "https://localhost:8080/config.html", - "configurationLocation": "none", - "description": "A list of the ambassadors at Alveus so that viewers can know more about them.", - "eulaTosUrl": "", - "hasChatSupport": false, - "iconUrl": "", - "iconUrls": {}, - "id": "m4ekmqj4n0nw5huja87u2zhhd5xvc4", - "installationCount": -42, - "liveConfigUrl": "", - "name": "Alveus Ambassadors", - "panelHeight": 300, - "privacyPolicyUrl": "", - "requestIdentityLink": false, - "requiredBroadcasterAbilities": [], - "screenshotUrls": [], - "sku": "", - "state": "Testing", - "subscriptionsSupportLevel": "none", - "summary": "Information about the ambassadors at Alveus.", - "supportEmail": "abdullahmorrison@gmail.com", - "vendorCode": "", - "version": "0.0.1", - "viewerSummary": "", - "viewerUrl": "https://localhost:8080/panel.html", - "viewerUrls": { - "mobile": "https://localhost:8080/mobile.html", - "panel": "https://localhost:8080/panel.html" - }, - "views": { - "mobile": { - "viewerUrl": "https://localhost:8080/mobile.html" - }, - "panel": { - "viewerUrl": "https://localhost:8080/panel.html", - "height": 300, - "canLinkExternalContent": false - }, - "config": { - "viewerUrl": "https://localhost:8080/config.html", - "canLinkExternalContent": false - } - }, - "whitelistedConfigUrls": [], - "whitelistedPanelUrls": [] - }, - "frontendCommand": "", - "frontendFolderName": "", - "name": "Alveus Animals", - "usingRandomFrontendHostingPort": false, - "version": 3 -} diff --git a/eslint.config.mjs b/eslint.config.mjs index 36308c8b..3475ef39 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -10,7 +10,6 @@ export default tseslint.config( ...eslint.configs.recommended, }, ...tseslint.configs.recommended, - // @ts-expect-error - incorrect types reactPlugin.configs.flat.recommended, { name: "prettier/config", diff --git a/src/react-app-env.d.ts b/src/react-app-env.d.ts index d6862b76..eab71b91 100644 --- a/src/react-app-env.d.ts +++ b/src/react-app-env.d.ts @@ -3,12 +3,14 @@ /// declare namespace NodeJS { - interface ProcessEnv { - readonly NODE_ENV: "development" | "production"; - readonly REACT_APP_CHAT_COMMANDS_PRIVILEGED_USERS: string; - readonly REACT_APP_DEFAULT_CHANNEL_NAMES: string; - readonly REACT_APP_TEST_CHANNEL_NAMES: string | undefined; - } + type ProcessEnv = Record & { + readonly NODE_ENV?: "development" | "production"; + readonly REACT_APP_CHAT_COMMANDS_PRIVILEGED_USERS?: string; + readonly REACT_APP_DEFAULT_CHANNEL_NAMES?: string; + readonly REACT_APP_EXTRA_CHANNEL_NAMES?: string; + readonly REACT_APP_TEST_CHANNEL_NAMES?: string; + readonly REACT_APP_WEBSITE_URL?: string; + }; } declare module "*.png" { @@ -35,13 +37,3 @@ declare module "*.svg" { const src: string; export default src; } - -declare module "*.module.scss" { - const classes: { readonly [key: string]: string }; - export default classes; -} - -declare module "*.module.sass" { - const classes: { readonly [key: string]: string }; - export default classes; -}