[ ] 👎 Sweep Needs Improvement
I created this PR to fix the failing GitHub Actions.## Description
This PR addresses the issue of the failing GitHub Actions due to a missing "lint" script. The problem was identified in the .github/workflows/nodejs.yml file, where the linting step is expected to run for both the backend and frontend directories. The error logs indicated that the "lint" script was not defined in the package.json files of these directories, leading to the failure of the GitHub Actions run.
To resolve this issue, ESLint, a popular linting tool for JavaScript and TypeScript projects, was set up for both the backend and frontend. This involved creating ESLint configuration files in both directories to define the linting rules and environment, and modifying the package.json files to include a "lint" script that runs ESLint with the appropriate configurations.
Summary of Changes
Created .eslintrc.json in the backend directory with ESLint rules and environment suitable for a Node.js project.
Created .eslintrc.json in the frontend directory with ESLint rules and environment suitable for a React project.
Modified package.json in the backend directory to include a "lint" script that runs ESLint on all JavaScript files within the directory.
Modified package.json in the frontend directory to include a "lint" script that runs ESLint on all JavaScript and JSX files within the directory.
These changes not only fix the GitHub Actions workflow but also enhance the project's maintainability and code quality by enforcing consistent coding standards.
PR Feedback (click)
.github/workflows/nodejs.yml
file, where the linting step is expected to run for both the backend and frontend directories. The error logs indicated that the "lint" script was not defined in thepackage.json
files of these directories, leading to the failure of the GitHub Actions run.To resolve this issue, ESLint, a popular linting tool for JavaScript and TypeScript projects, was set up for both the backend and frontend. This involved creating ESLint configuration files in both directories to define the linting rules and environment, and modifying the
package.json
files to include a "lint" script that runs ESLint with the appropriate configurations.Summary of Changes
.eslintrc.json
in the backend directory with ESLint rules and environment suitable for a Node.js project..eslintrc.json
in the frontend directory with ESLint rules and environment suitable for a React project.package.json
in the backend directory to include a "lint" script that runs ESLint on all JavaScript files within the directory.package.json
in the frontend directory to include a "lint" script that runs ESLint on all JavaScript and JSX files within the directory.These changes not only fix the GitHub Actions workflow but also enhance the project's maintainability and code quality by enforcing consistent coding standards.