Skip to content

infra: lint all existing jsdocs #2408

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

Merged
merged 5 commits into from
Sep 23, 2023
Merged

Conversation

ST-DDT
Copy link
Member

@ST-DDT ST-DDT commented Sep 19, 2023

This PR fixes all lint errors that aren't Missing JSDoc comment in scripts.

Note, that currently the jsdocs lint rules don't apply to the scripts at all.

@ST-DDT ST-DDT added c: docs Improvements or additions to documentation c: chore PR that doesn't affect the runtime behavior p: 1-normal Nothing urgent labels Sep 19, 2023
@ST-DDT ST-DDT added this to the vAnytime milestone Sep 19, 2023
@ST-DDT ST-DDT requested review from a team September 19, 2023 23:12
@ST-DDT ST-DDT self-assigned this Sep 19, 2023
@codecov
Copy link

codecov bot commented Sep 19, 2023

Codecov Report

Merging #2408 (5884e14) into next (74eeccc) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Additional details and impacted files
@@           Coverage Diff           @@
##             next    #2408   +/-   ##
=======================================
  Coverage   99.60%   99.60%           
=======================================
  Files        2802     2802           
  Lines      252486   252492    +6     
  Branches     1103     1104    +1     
=======================================
+ Hits       251499   251505    +6     
  Misses        960      960           
  Partials       27       27           
Files Changed Coverage Δ
src/modules/date/index.ts 100.00% <100.00%> (ø)
src/modules/helpers/index.ts 99.12% <100.00%> (+<0.01%) ⬆️

... and 2 files with indirect coverage changes

@matthewmayer
Copy link
Contributor

Can you make this part of preflight so lint issues dont creep back in?

@ST-DDT
Copy link
Member Author

ST-DDT commented Sep 20, 2023

Theoretically yes. The problem is that I didnt fix the missing jsdoc lint issues. So we either had to fix them or disable the rule for scripts (and tests).
The non jsdocs lint checks are enabled for our scripts.

I'm somewhat torn on this and would like to hear more opinions on this.

Shinigami92
Shinigami92 previously approved these changes Sep 20, 2023
@Shinigami92
Copy link
Member

I'm somewhat torn on this and would like to hear more opinions on this.

JSDocs are checked in src because they are provided when consumers of Faker hover over the methods and stuff.
The scripts are internal and not published/exposed, so "I" don't care about JSDocs in scripts, they just help to remember what is for what when coming back a half year later and try to find stuff out. They are not public-docs.

@ST-DDT ST-DDT requested a review from a team September 20, 2023 11:40
@matthewmayer
Copy link
Contributor

Agree Jsdocs in the scripts are a nice to have but much much less important than in src.

If they exist they should probably be linted correctly, but missing jsdocs in scripts is not important for self explanatory methods.

@ST-DDT
Copy link
Member Author

ST-DDT commented Sep 20, 2023

I enabled the jsdoc checks for our entire code base, but only require jsdocs for src.

@ST-DDT ST-DDT requested a review from Shinigami92 September 20, 2023 21:39
@ST-DDT ST-DDT changed the title chore: fix some lint errors in script jsdocs chore: lint all existing jsdocs Sep 20, 2023
@ST-DDT ST-DDT added c: infra Changes to our infrastructure or project setup and removed c: chore PR that doesn't affect the runtime behavior labels Sep 20, 2023
@ST-DDT ST-DDT changed the title chore: lint all existing jsdocs infra: lint all existing jsdocs Sep 20, 2023
@ST-DDT ST-DDT requested review from Shinigami92 and a team September 21, 2023 10:02
@ST-DDT ST-DDT requested a review from a team September 21, 2023 12:57
@xDivisionByZerox xDivisionByZerox enabled auto-merge (squash) September 23, 2023 23:22
@xDivisionByZerox xDivisionByZerox merged commit 24415ee into next Sep 23, 2023
@Shinigami92 Shinigami92 deleted the chore/lint/scripts/jsdocs branch September 23, 2023 23:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: docs Improvements or additions to documentation c: infra Changes to our infrastructure or project setup p: 1-normal Nothing urgent
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants