Skip to content

darky/glatch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

glatch

Package Version Hex Docs

logo

Gleam type check using pattern matching

gleam add glatch
import glatch.{IsString}
import gleam/string

pub fn main() {
  case glatch.get_type("Lucy") {
    IsString(_) -> "Hello, 𓇼"
    unknown -> "Who are you? " <> string.inspect(unknown)
  }
}

Further documentation can be found at https://hexdocs.pm/glatch.

Current status

Native / Stdlib

  • String
  • Int
  • Float
  • Bool
  • List
    • nested type check
    • empty type check
  • Option
    • Some type check
    • None type check
  • Result
    • Ok type check
    • Error type check
  • Dict
    • key type check
    • value type check
    • empty type check
  • Tuple
    • Arity 0-6

Development

gleam run   # Run the project
gleam test  # Run the tests
gleam shell # Run an Erlang shell

About

Gleam type check using pattern matching

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages