Skip to main content

Crate typedflake_macros

Crate typedflake_macros 

Source
Expand description

Procedural macros for TypedFlake.

Use them through the typedflake crate, which re-exports and documents them.

Attribute Macros§

typedflake
Declares a Snowflake-style ID type.

Derive Macros§

Postgres
Implements postgres-types’ ToSql and FromSql for an i64 ID type, stored as BIGINT.
Serde
Implements Serde’s Serialize and Deserialize for an ID type.
SerdeEncoded
Implements Serde’s Serialize and Deserialize for an ID type, using its encoded text.
SqlxPostgres
Implements SQLx’s PostgreSQL Type, Encode, Decode, and array support for an i64 ID type, stored as BIGINT.
TypedNode
Splits the node field of an ID into named parts.