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

JSDoc, deno.jsonc, return type tweaks; prep for JSR.io publish test #8

Merged
merged 14 commits into from
Jun 14, 2024

Conversation

filmaj
Copy link

@filmaj filmaj commented Jun 5, 2024

Following the docs here to try to publish something to jsr.io: https://jsr.io/docs/publishing-packages

Also added an extra test to bump coverage up by a couple %, removing deprecated fields from deno.jsonc, tweaking JSdocs to be consistent, and made a slightly more accurate return type for the Message Boundary protocol.

Post-Merge TODOs

  • Remove the ?subdir querystring parameter to the deno.land webhook

…ting a message boundary protocol implementation (it always contains a `getCLIFlags` method), removed deprecated nested options from deno.jsonc, changed coverage task to report detailed coverage.
@filmaj filmaj added documentation Improvements or additions to documentation enhancement New feature or request labels Jun 5, 2024
@filmaj filmaj self-assigned this Jun 5, 2024
@filmaj filmaj requested a review from a team as a code owner June 5, 2024 15:31
"fmt": {
"files": {
Copy link
Author

Choose a reason for hiding this comment

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

The files and options keys are deprecated, and deno would warn about using them, so removed them.

src/mod.ts Outdated Show resolved Hide resolved
export const MessageBoundaryProtocol = function (args: string[]): Protocol {
export const MessageBoundaryProtocol = function (
args: string[],
): Required<Pick<Protocol, "getCLIFlags">> & Protocol {
Copy link
Author

Choose a reason for hiding this comment

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

The base Protocol interface sets getCLIFlags as an optional key. However, the Message Boundary protocol always returns this key, so tweaking the type to make that a required property.

Copy link

codecov bot commented Jun 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.77%. Comparing base (761d788) to head (2aec1d9).

Additional details and impacted files
@@            Coverage Diff             @@
##             main       #8      +/-   ##
==========================================
+ Coverage   91.93%   95.77%   +3.83%     
==========================================
  Files           3        1       -2     
  Lines          62       71       +9     
  Branches        5        5              
==========================================
+ Hits           57       68      +11     
+ Misses          5        3       -2     

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

Copy link
Contributor

@WilliamBergamin WilliamBergamin left a comment

Choose a reason for hiding this comment

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

This is awesome 💯

@@ -1,31 +1,39 @@
{
"$schema": "https://deno.land/x/deno/cli/schemas/config-file.v1.json",
"name": "@slack/protocols",
"version": "0.0.2-pre.2",
"exports": {
Copy link
Contributor

@WilliamBergamin WilliamBergamin Jun 12, 2024

Choose a reason for hiding this comment

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

Love this export implementation 💯

src/mod.ts Show resolved Hide resolved
@filmaj filmaj requested a review from WilliamBergamin June 12, 2024 19:28
@filmaj
Copy link
Author

filmaj commented Jun 12, 2024

@WilliamBergamin i added a publish workflow for JSR, just based on what jsr's site says: https://jsr.io/docs/publishing-packages#publishing-from-github-actions

Copy link
Contributor

@WilliamBergamin WilliamBergamin left a comment

Choose a reason for hiding this comment

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

This looks good 💯 I think we can merge and fix forward if we encounter issues

@filmaj filmaj merged commit a4f8b90 into main Jun 14, 2024
6 checks passed
@filmaj filmaj deleted the jsdoc-tweaks branch June 14, 2024 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants