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

Update documentation for v0.21 deprecations #261

Merged
merged 2 commits into from
Jan 8, 2024

Conversation

silverlyra
Copy link
Contributor

👋🏻 Hello! I used this base64 crate for the first time this past week in a project. Honestly when I started, I first didn’t even look at the documentation – I ran a cargo add base64, and then tried typing base64::decode in my editor.

That function did exist, and does exactly what I wanted (decode canonical base64 input using the standard alphabet), but it showed as deprecated. So I went to docs.rs to see what I was supposed to use instead, and I found the current crate documentation difficult to understand how to set up base64 decoding and/or encoding.

I appreciate this crate and the flexibility it offers for the nuances of base64 (different alphabets, padding = character handling), and here I’ve made an attempt to update the crate documentation to help a new user navigate those nuances, and successfully start decoding/encoding data.

side by side base64 rustdoc

In the updated documentation, I’ve made sure there’s a code sample immediately visible which shows how to do decoding and encoding using default settings, and I (attempt to) explain enough of the nuance of base64 to empower users who would want non-default choices to get the setup they need.

I’ve submitted many more pull requests on code than on prose 😅 – I’m not sure how you’d want to review this, but I can keep workshopping the text. 🙏🏻 I also made some tweaks to the existing base64.rs example.

@marshallpierce
Copy link
Owner

Thanks very much for the thoughtful improvements! I've taken care of the conflicts (#263) and tweaked a couple of minor things (notably, not renaming the engine imports to BASE64 to highlight to the hasty reader that they are in fact different).

marshallpierce added a commit that referenced this pull request Jan 8, 2024
@marshallpierce marshallpierce merged commit 97d9180 into marshallpierce:master Jan 8, 2024
5 checks passed
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.

None yet

2 participants