Crates.io | jdt_maybe_reference |
lib.rs | jdt_maybe_reference |
version | 0.1.12 |
created_at | 2025-01-01 06:40:36.335349+00 |
updated_at | 2025-07-15 21:42:26.604322+00 |
description | MaybeReference is a utility crate that establishes an enum to use where a value may either be a single JSON string or a JSON object |
homepage | |
repository | https://gitlab.com/justindthomas/maybe_reference |
max_upload_size | |
id | 1500634 |
size | 10,700 |
This is a utility crate that establishes an enum to use to match a JSON value that may be a single string (a "reference"), a reference in the form of {"id": "reference"}
or an object.
"https://example.com/id/uuid"
{"id": "reference"}
{"id": "reference", "content": "somecontent"}
These would all match to MaybeReference<String> as ::Reference, ::Identifier, ::Actual, respectively.