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

chore: working on migrating instanceof examples to switch #1391

Merged
merged 6 commits into from
Jul 17, 2024

Conversation

cprice404
Copy link
Contributor

No description provided.

@cprice404 cprice404 requested a review from a team July 16, 2024 23:02
case CacheGetResponse.Error:
throw new Error(
`An error occurred while attempting to get key 'test-key' from cache 'test-cache': ${result.errorCode()}: ${result.toString()}`
);
}
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

most of the changes are in the next file, which is hidden due to "large diffs" 🤦

Copy link
Contributor

@malandis malandis left a comment

Choose a reason for hiding this comment

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

Caught a couple small issues.

A non-blocker but for us to consider:

  • Some of the inline comments are a guide to our users, eg in the topics examples where we set up a subscription, then publish.
  • Others are comments that look more like to us. Can consider adding some metadata to the comment or making a comment "region" that is excluded from the docs

Comment on lines +486 to +487
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
console.log(`List fetched successfully: ${result.valueList()}`);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is there a way to write this line so we can remove the eslint suppression from the docs?

Comment on lines +1403 to +1404
// Need to close the stream before the example ends or else the example will hang.
result.unsubscribe();
Copy link
Contributor

Choose a reason for hiding this comment

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

See my comment about the parentheticals to ourselves vs users

Copy link
Contributor Author

Choose a reason for hiding this comment

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

this seems useful for users too though?

@cprice404 cprice404 merged commit 2b7efc1 into main Jul 17, 2024
13 checks passed
@cprice404 cprice404 deleted the remove-instanceof branch July 17, 2024 20:02
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.

2 participants