{"id":15059334,"url":"https://github.com/lue-bird/elm-syntax-format","last_synced_at":"2026-03-01T09:32:38.856Z","repository":{"id":256652581,"uuid":"856035375","full_name":"lue-bird/elm-syntax-format","owner":"lue-bird","description":"pretty print elm-syntax like elm-format","archived":false,"fork":false,"pushed_at":"2026-02-02T13:19:18.000Z","size":2791,"stargazers_count":9,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-02-02T16:39:34.434Z","etag":null,"topics":["ast","elm","elm-format","elm-syntax","pretty-print"],"latest_commit_sha":null,"homepage":"https://dark.elm.dmy.fr/packages/lue-bird/elm-syntax-format/latest/","language":"Elm","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/lue-bird.png","metadata":{"files":{"readme":"README.md","changelog":"changes.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-09-11T21:52:45.000Z","updated_at":"2026-02-02T13:19:22.000Z","dependencies_parsed_at":"2024-09-12T08:11:46.838Z","dependency_job_id":"bc3a5574-bbd3-481d-a5fc-14ec816d9be7","html_url":"https://github.com/lue-bird/elm-syntax-format","commit_stats":null,"previous_names":["lue-bird/elm-syntax-format"],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/lue-bird/elm-syntax-format","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-syntax-format","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-syntax-format/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-syntax-format/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-syntax-format/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lue-bird","download_url":"https://codeload.github.com/lue-bird/elm-syntax-format/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-syntax-format/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29965609,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-01T06:55:38.174Z","status":"ssl_error","status_checked_at":"2026-03-01T06:53:04.810Z","response_time":124,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":["ast","elm","elm-format","elm-syntax","pretty-print"],"created_at":"2024-09-24T22:41:39.897Z","updated_at":"2026-03-01T09:32:38.829Z","avatar_url":"https://github.com/lue-bird.png","language":"Elm","funding_links":[],"categories":[],"sub_categories":[],"readme":"Pretty print an [`elm-syntax`](https://dark.elm.dmy.fr/packages/stil4m/elm-syntax/latest/) tree as [`elm-format`](https://github.com/avh4/elm-format) would\n(breaking lines and inserting comments in the right places).\n\n```elm\nimport ElmSyntaxPrint\nimport ElmSyntaxParserLenient\n\n\"\"\"\nmodule   Sample  exposing(...)\nplus2 (n)= {- this adds 2-} n\n+\n2\n\"\"\"\n    |\u003e ElmSyntaxParserLenient.run ElmSyntaxParserLenient.module_\n    |\u003e Maybe.map\n        (\\syntaxModule -\u003e\n            syntaxModule\n                |\u003e ElmSyntaxPrint.module_\n                |\u003e ElmSyntaxPrint.toString\n        )\n--\u003e\nJust \"\"\"module Sample exposing (..)\n\n\nplus2 n =\n    {- this adds 2 -}\n    n\n        + 2\n\"\"\"\n```\n\nTo try it out, you can\nrun [this node script](https://github.com/lue-bird/elm-syntax-format/tree/main/node-elm-syntax-format).\n\nIf you want to _generate_ code, better bets are [`mdgriffith/elm-codegen`](https://dark.elm.dmy.fr/packages/mdgriffith/elm-codegen/latest/) or [`the-sett/elm-syntax-dsl`](https://dark.elm.dmy.fr/packages/the-sett/elm-syntax-dsl/latest/).\n\n## known deviations in printing\n  - ranges of `of`, `exposing` and `as` are needed to determine whether they should be on the next line or at the end of last line\n  - ranges of `=`, `:`, `,`, `|`, `-\u003e`, pattern `::`, the operators and the keywords are needed to determine whether comments are before or after\n  - function types outputting a parenthesized function do not preserve the parens because type parens are not stored in the syntax tree\n  - comments before/after parenthesized types will get eaten because type parens are not stored in the syntax tree\n  - some floats in exponent representation are formatted to without it and the other way around\n  - handling int (and float?) overflow (elm-format itself seems to have issues here, too https://github.com/avh4/elm-format/issues/635)\n  - formatting documentation markdown\n\nPlease [report](https://github.com/lue-bird/elm-syntax-format/issues/new) others you notice \u003c3\n\n## performance problems?\nPlease [open an issue](https://github.com/lue-bird/elm-syntax-format/issues/new).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flue-bird%2Felm-syntax-format","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flue-bird%2Felm-syntax-format","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flue-bird%2Felm-syntax-format/lists"}