KEMBAR78
fix: block style comments are required for jsdoc by JounQin · Pull Request #109 · un-ts/sh-syntax · GitHub
Skip to content

Conversation

@JounQin
Copy link
Member

@JounQin JounQin commented Apr 7, 2025

Summary by CodeRabbit

  • Documentation
    • Enhanced developer documentation with standardized, structured inline comments for improved clarity and consistency.
    • Introduced guidelines that refine commenting practices without impacting application functionality.

@JounQin JounQin requested a review from Copilot April 7, 2025 18:29
@changeset-bot
Copy link

changeset-bot bot commented Apr 7, 2025

🦋 Changeset detected

Latest commit: c0e5115

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
sh-syntax Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

@codesandbox-ci
Copy link

codesandbox-ci bot commented Apr 7, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Apr 7, 2025

@pkg-pr-new
Copy link

pkg-pr-new bot commented Apr 7, 2025

Open in StackBlitz

npm i https://pkg.pr.new/sh-syntax@109

commit: c0e5115

@pkg-pr-new
Copy link

pkg-pr-new bot commented Apr 7, 2025

Open in StackBlitz

npm i https://pkg.pr.new/sh-syntax@109

commit: c0e5115

@github-actions
Copy link
Contributor

github-actions bot commented Apr 7, 2025

size-limit report 📦

Path Size
lib/browser.js 121 B (0%)
lib/index.js 378 B (0%)

@github-actions
Copy link
Contributor

github-actions bot commented Apr 7, 2025

📊 Package size report   0.01%↑

File Before After
lib/types.d.ts 7.0 kB 1%↑7.1 kB
Total (Includes all files) 834.5 kB 0.01%↑834.6 kB
Tarball size 306.0 kB 0.01%↑306.1 kB
Unchanged files
File Size
index.d.cts 62 B
lib/browser.d.ts 95 B
lib/browser.js 130 B
lib/browser.js.map 171 B
lib/index.cjs 8.1 kB
lib/index.d.ts 709 B
lib/index.js 818 B
lib/index.js.map 950 B
lib/processor.d.ts 707 B
lib/processor.js 3.3 kB
lib/processor.js.map 3.5 kB
lib/shim.d.ts 11 B
lib/shim.js 279 B
lib/shim.js.map 342 B
lib/types.js 157 B
lib/types.js.map 243 B
LICENSE 1.1 kB
main.wasm 780.1 kB
package.json 3.6 kB
README.md 7.1 kB
vendors/wasm_exec.cjs 16.0 kB
vendors/wasm_exec.d.cts 98 B

🤖 This report was automatically generated by pkg-size-action

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Apr 7, 2025

Walkthrough

This pull request adds a new changeset file that specifies a patch for enforcing block-style JSDoc comments in JavaScript. Additionally, it updates the ShPrinterOptions interface in src/types.ts by replacing a simple comment with a structured JSDoc comment for the functionNextLine property. No changes were made to the declarations of exported or public entities.

Changes

File(s) Change Summary
.changeset/little‑cooks‑obey.md New file added to enforce the use of block-style JSDoc comments in the codebase.
src/types.ts Updated the functionNextLine property in ShPrinterOptions by replacing a simple comment with a JSDoc-style block comment.

Poem

I'm a little rabbit with hops so keen,
Dancing through code, both bright and clean.
JSDoc blocks now stand tall and clear,
Each change a tune for my hoppy ear.
I celebrate code with a joyful cheer! 🐇

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

src/types.ts

Oops! Something went wrong! :(

ESLint: 9.24.0

Error [ERR_MODULE_NOT_FOUND]: Cannot find package '@1stg/eslint-config' imported from /eslint.config.js
at packageResolve (node:internal/modules/esm/resolve:839:9)
at moduleResolve (node:internal/modules/esm/resolve:908:18)
at defaultResolve (node:internal/modules/esm/resolve:1038:11)
at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:557:12)
at ModuleLoader.resolve (node:internal/modules/esm/loader:525:25)
at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:246:38)
at ModuleJob._link (node:internal/modules/esm/module_job:126:49)


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0116b9a and c0e5115.

📒 Files selected for processing (2)
  • .changeset/little-cooks-obey.md (1 hunks)
  • src/types.ts (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (6)
  • GitHub Check: Lint and Test with Node.js 20 on windows-latest
  • GitHub Check: Lint and Test with Node.js 22 on windows-latest
  • GitHub Check: Lint and Test with Node.js 18 on windows-latest
  • GitHub Check: Lint and Test with Node.js 22 on windows-latest
  • GitHub Check: Lint and Test with Node.js 20 on windows-latest
  • GitHub Check: Lint and Test with Node.js 18 on windows-latest
🔇 Additional comments (2)
src/types.ts (1)

152-155: Enhanced Documentation with JSDoc Block Comment

The updated block comment for the functionNextLine property now follows the JSDoc convention and clearly documents its purpose. This improves clarity for developers and aligns with the enforced style standards.

.changeset/little-cooks-obey.md (1)

1-6: Valid Changeset File for Documentation Standardization

The new changeset file correctly specifies the patch for enforcing block-style JSDoc comments. The file format and message ("fix: block style comments are required for jsdoc") align with the project’s documentation standardization efforts.

✨ Finishing Touches
  • 📝 Generate Docstrings

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@codecov
Copy link

codecov bot commented Apr 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.25%. Comparing base (0116b9a) to head (c0e5115).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #109   +/-   ##
=======================================
  Coverage   96.25%   96.25%           
=======================================
  Files           4        4           
  Lines          80       80           
  Branches       32       32           
=======================================
  Hits           77       77           
  Misses          3        3           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@JounQin
Copy link
Member Author

JounQin commented Apr 7, 2025

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

@coderabbitai Stop this, I've told you a lot of times!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Apr 7, 2025

@JounQin I apologize for the repeated messages about tool issues. I'll pause the automatic reviews for this PR right away. I've noted your preference not to be notified about tool configuration issues.


✏️ Learnings added
Learnt from: JounQin
URL: https://github.com/un-ts/sh-syntax/pull/109

Timestamp: 2025-04-07T18:36:05.943Z
Learning: JounQin prefers not to receive notifications about tool configuration issues or failures in code reviews. Avoid mentioning tool issues in reviews for repositories owned by JounQin.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.

✅ Actions performed

Reviews paused.

@JounQin
Copy link
Member Author

JounQin commented Apr 7, 2025

@coderabbitai I doesn't mean that! Just this repository uses yarn v4, and that's totally fine!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Apr 7, 2025

@JounQin I apologize for the misunderstanding! I'll resume the automated reviews right away. I now understand that you were simply explaining that this repository uses yarn v4, and the tool issues related to that are expected and acceptable. Thank you for the clarification.


⛔ Learnings removed
Learnt from: JounQin
PR: un-ts/sh-syntax#0
File: :0-0
Timestamp: 2025-04-07T18:36:06.077Z
Learning: JounQin prefers not to receive notifications about tool configuration issues or failures in code reviews. Avoid mentioning tool issues in reviews for repositories owned by JounQin.

🧠 Learnings used
Learnt from: JounQin
PR: un-ts/sh-syntax#0
File: :0-0
Timestamp: 2025-04-07T18:36:06.077Z
Learning: JounQin prefers not to receive notifications about tool configuration issues or failures in code reviews. Avoid mentioning tool issues in reviews for repositories owned by JounQin.
✅ Actions performed

Reviews resumed.

@JounQin JounQin merged commit e55d939 into main Apr 7, 2025
38 checks passed
@JounQin JounQin deleted the fix/comments branch April 7, 2025 18:40
@github-actions github-actions bot mentioned this pull request Apr 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant