snowcord
Small Discord Snowflake converter
Installation
-
Add the dependency to your
shard.yml
:dependencies: snowcord: github: asdffdsdaf/snowcord
-
Run
shards install
Usage
require "snowcord"
Snowcord.snowflake_at # Convert current time to Discord Snowflake
Snowcord.to_snowflake(unix) # Convert unix timestamp to Discord Snowflake
Snowcord.to_unix(snowflake) # Convert Discord Snowflake to unix timestamp