Skip to content

Commit

Permalink
Add linting to project
Browse files Browse the repository at this point in the history
  • Loading branch information
CalPinSW committed Aug 23, 2024
1 parent bf5f0d6 commit b2544fa
Show file tree
Hide file tree
Showing 5 changed files with 422 additions and 39 deletions.
1 change: 1 addition & 0 deletions frontend/build/build-common.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { config } from "dotenv";

config();

const define = {
Expand Down
2 changes: 0 additions & 2 deletions frontend/build/server.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ import * as esbuild from "esbuild";
import { buildOptions } from "./build-common.mjs";
import http from "node:http";

const watchDirectories = ["src/*.{ts,tsx}"];

const runServer = async () => {
const ctx = await esbuild.context(buildOptions);

Expand Down
9 changes: 5 additions & 4 deletions frontend/eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@ import tseslint from "typescript-eslint";
import pluginReact from "eslint-plugin-react";

export default [

{
languageOptions: { globals: globals.browser }
languageOptions: { globals: {...globals.browser, ...globals.node}, },
},
pluginJs.configs.recommended,
...tseslint.configs.recommended,
pluginReact.configs.flat.recommended,
{
files: ["src/**/*.js"],
ignores: ["**/*.tsx"],
rules: {"unused-imports/no-unused-imports": "error"}
},
{
ignores: ["public/bundle.js"],
},
];
Loading

0 comments on commit b2544fa

Please sign in to comment.