{"id":16336402,"url":"https://github.com/justinwoo/purescript-chirashi","last_synced_at":"2026-01-24T11:37:08.878Z","repository":{"id":58225360,"uuid":"150866576","full_name":"justinwoo/purescript-chirashi","owner":"justinwoo","description":"An easy way to work with Errors by inserting a Variant, and reading it out later.","archived":false,"fork":false,"pushed_at":"2019-05-30T10:04:36.000Z","size":5,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-19T13:23:42.164Z","etag":null,"topics":["error","purescript","variant"],"latest_commit_sha":null,"homepage":"","language":"PureScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justinwoo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-29T13:26:35.000Z","updated_at":"2025-05-13T22:52:12.000Z","dependencies_parsed_at":"2022-08-31T04:10:16.759Z","dependency_job_id":null,"html_url":"https://github.com/justinwoo/purescript-chirashi","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/justinwoo/purescript-chirashi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinwoo%2Fpurescript-chirashi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinwoo%2Fpurescript-chirashi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinwoo%2Fpurescript-chirashi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinwoo%2Fpurescript-chirashi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justinwoo","download_url":"https://codeload.github.com/justinwoo/purescript-chirashi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinwoo%2Fpurescript-chirashi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28726981,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-24T10:24:43.181Z","status":"ssl_error","status_checked_at":"2026-01-24T10:24:36.112Z","response_time":89,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["error","purescript","variant"],"created_at":"2024-10-10T23:44:01.847Z","updated_at":"2026-01-24T11:37:08.854Z","avatar_url":"https://github.com/justinwoo.png","language":"PureScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Purescript-Chirashi\n\n[![Build Status](https://travis-ci.org/justinwoo/purescript-chirashi.svg?branch=master)](https://travis-ci.org/justinwoo/purescript-chirashi)\n\n[Docs on Pursuit](https://pursuit.purescript.org/packages/purescript-chirashi)\n\nAn easy way to work with `Error`s by inserting a `Variant`, and reading it out later.\n\nWorks by subclassing Error.\n\n![](https://i.imgur.com/468wLLl.jpg)\n\n## Usage\n\n```purs\ntype ErrorVariant = Variant\n  ( apple :: String\n  , banana :: { info :: String }\n  , cherry :: Unit\n  )\n\nmain = do\n  let\n    knownVariant :: ErrorVariant\n    knownVariant = Variant.inj (SProxy :: SProxy \"banana\") { info: \"hello\" }\n    knownError = Chirashi.mkVariantError knownVariant\n    resultKnownError = Chirashi.readVariant knownError\n\n  Assert.assertEqual\n    { expected: Just knownVariant\n    , actual: resultKnownError\n    }\n```\n\nSee tests for more examples.\n\n## Other links\n\nFor more ideas on what you could do with this library, see [Ochadzuke](https://github.com/justinwoo/purescript-ochadzuke#usage).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinwoo%2Fpurescript-chirashi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustinwoo%2Fpurescript-chirashi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinwoo%2Fpurescript-chirashi/lists"}