Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Progress: Fix eslint error #335

Open
hoangnt2 opened this issue Oct 3, 2024 · 7 comments
Open

Progress: Fix eslint error #335

hoangnt2 opened this issue Oct 3, 2024 · 7 comments
Labels
help wanted Extra attention is needed refactor

Comments

@hoangnt2
Copy link
Contributor

hoangnt2 commented Oct 3, 2024

No Item Path Status PIC Note
1 Home Page + Auth Page /src/app/[locale]/home DONE @hoangnt2  
2 Project Page /src/app/[locale]/projects IN PROGRESS  @amritkv  
3 Component Page /src/app/[locale]/components DONE @hoangnt2  
4 License Page /src/app/[locale]/licenses DONE @hoangnt2  
5 ECC page /src/app/[locale]/ecc DONE  @hoangnt2
6 Request page /src/app/[locale]/requests DONE  @amritkv  
7 Search page /src/app/[locale]/search DONE   @hoangnt2  
8 Preferences page /src/app/[locale]/preferences DONE @hoangnt2  
9 Vulnerabilities page /src/app/[locale]/vulnerabilities DONE @duonglq-tsdv  
10 Users page (ADMIN) /src/app/[locale]/admin/users DONE   @deo002  
11 Licenses page (ADMIN) /src/app/[locale]/admin/licenses DONE @duonglq-tsdv  
12 Database Sanitation (ADMIN) /src/app/[locale]/admin/databaseSanitation DONE  @deo002  
13 Vendors page (ADMIN) /src/app/[locale]/admin/vendors DONE   @deo002  
14 Common components /src/components IN PROGRESS @hoangnt2  
15 Object types /src/object-types N/A   
16 Services /src/services DONE  @deo002  
17 Api Routes /src/app/api IN PROGRESS  @deo002
18 Package Page /src/app/[locale]/packages DONE @duonglq-tsdv  
@hoangnt2 hoangnt2 added help wanted Extra attention is needed refactor labels Oct 3, 2024
@hoangnt2
Copy link
Contributor Author

hoangnt2 commented Oct 3, 2024

@heliocastro @amritkv @deo002,
I have listed all item we need to fix and their status. If you are fixing any items, please edit table above to make it easier for others to follow

@hoangnt2
Copy link
Contributor Author

@amritkv, @deo002, as I see in the above table, the Request page and Api Routes are marked as DONE.
But when I run npm run lint on latest commit of main branch (8a137e7), I still see the errors. Did I miss something?

Request page:
image

Api Routes:
image

@amritkv
Copy link
Contributor

amritkv commented Oct 29, 2024

@amritkv, @deo002, as I see in the above table, the Request page and Api Routes are marked as DONE. But when I run npm run lint on latest commit of main branch (8a137e7), I still see the errors. Did I miss something?

Request page: image

Api Routes: image

Hey @hoangnt2 ! What I can see, there are few error like use of any, although I haven't used any type in requests/components/Requests.tsx
Need to cross-check these error. And moreover we all are using same version of linter right ?

@hoangnt2
Copy link
Contributor Author

@amritkv I think we are using same version of linter. In requests/components/Requests.tsx file. The any error come from fetchData function:
image
Because response.json() will return any type

You can fix this error by convert it to EmbeddedModerationRequest as below
image

I am not sure why VSCode does not show this error, the error only appears when I run the command npm run lint

@deo002
Copy link
Contributor

deo002 commented Oct 30, 2024

@hoangnt2 @amritkv VS Code didn't show these errors and I didn't run npm run lint. I'll update the list and start to work on it.

@amritkv
Copy link
Contributor

amritkv commented Oct 30, 2024

@amritkv I think we are using same version of linter. In requests/components/Requests.tsx file. The any error come from fetchData function: image Because response.json() will return any type

You can fix this error by convert it to EmbeddedModerationRequest as below image

I am not sure why VSCode does not show this error, the error only appears when I run the command npm run lint

@hoangnt2 @deo002 Same for me as well. I'll fix VS Code and update the changes.

@hoangnt2
Copy link
Contributor Author

@amritkv @deo002 thanks guys

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed refactor
Projects
None yet
Development

No branches or pull requests

3 participants