Skip to content

Commit

Permalink
Fix serde tag in tutorial (#72)
Browse files Browse the repository at this point in the history
> The tutorial contains a clear error: `#[serde(tag = "type")]`, but in
the YAML shown, the key used is `action`.

https://www.reddit.com/r/rust/comments/17035r0/comment/k3jouy3/

Suggested-by:  Chris Morgan <me@chrismorgan.info>
  • Loading branch information
ahdinosaur committed Oct 5, 2023
1 parent f42c1f5 commit 592235e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/pages/tutorial.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ We code our actions in Rust:

```rust
#[derive(Debug, serde::Deserialize)]
#[serde(tag = "type")]
#[serde(tag = "action")]
enum Action {
#[serde(rename = "set")]
Set {
Expand Down

1 comment on commit 592235e

@vercel
Copy link

@vercel vercel bot commented on 592235e Oct 5, 2023

Choose a reason for hiding this comment

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

Please sign in to comment.