{"id":13532058,"url":"https://github.com/slamdata/purescript-echarts","last_synced_at":"2025-10-22T21:25:13.589Z","repository":{"id":25916360,"uuid":"29357277","full_name":"slamdata/purescript-echarts","owner":"slamdata","description":"Purescript bindings for Baidu's Echarts library","archived":true,"fork":false,"pushed_at":"2023-06-14T21:04:03.000Z","size":825,"stargazers_count":36,"open_issues_count":2,"forks_count":16,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-01-10T19:07:01.871Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PureScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/slamdata.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2015-01-16T16:37:37.000Z","updated_at":"2024-01-30T19:51:42.000Z","dependencies_parsed_at":"2024-06-05T14:37:36.417Z","dependency_job_id":null,"html_url":"https://github.com/slamdata/purescript-echarts","commit_stats":{"total_commits":118,"total_committers":12,"mean_commits":9.833333333333334,"dds":0.576271186440678,"last_synced_commit":"502deae5847eeaa8100aa34648c725efed60c532"},"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slamdata%2Fpurescript-echarts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slamdata%2Fpurescript-echarts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slamdata%2Fpurescript-echarts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slamdata%2Fpurescript-echarts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/slamdata","download_url":"https://codeload.github.com/slamdata/purescript-echarts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246580546,"owners_count":20800113,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-08-01T07:01:07.863Z","updated_at":"2025-10-22T21:25:13.255Z","avatar_url":"https://github.com/slamdata.png","language":"PureScript","funding_links":[],"categories":["Languages"],"sub_categories":["PureScript"],"readme":"# purescript-echarts\n\nPurescript bindings for Baidu's [Enterprise Charts (Echarts) charting library](https://github.com/ecomfe/echarts).\n\n[![Latest release](http://img.shields.io/github/release/slamdata/purescript-echarts.svg)](https://github.com/slamdata/purescript-echarts/releases)\n[![Build status](https://travis-ci.org/slamdata/purescript-echarts.svg?branch=master)](https://travis-ci.org/slamdata/purescript-echarts)\n\n## API\n\nThis approach drastically differs with __v2.0.0__.\n\nAll basic echarts function are implemented as effectful functions. They are wrapped in `MonadEff` typeclass and could be used not only in `Eff` monad but in `Aff` and effectful transformers.\n\n`Option` object is constructed using `Writer` monad augmented with phantom rows. I.e. there is no any\nspecial type for `Option`, `Legend` or `Tooltip`, but they are `DSL PhantomRowsI` where `PhantomRowsI` is phantom row type.\n\nTo write a field to objects one should use function from `ECharts.Commands` module. Row label of this function indicates if this function could be used for building particular objects. For example, if you build something like `Pie` series object you can use function `name` because it has type `forall i. String -\u003e DSL (name :: I|i)` and `PieI` has this `name` label in its phantom part, but you can't use `symbol` because its type is `forall i. Symbol -\u003e DSL (symbol :: I|i)` and `PieI` hasn't `symbol` label.\n\n## Examples\n\nTo run examples\n```bash\nnpm run build\nnpm run serve\n```\nThen go to `localhost:5050`\n\n## Notes\n\n* To use this lib in your project you need to add `echarts` npm dependency to your project.\n* This branch isn't fully implemented yet, although it has all features that we currently use in slamdata.\n* `Writer`'s log is `Array (Tuple String Foreign)`. There are three different functions that builds sub-dsls: `buildObj` takes pairs from log and write `Foreign`s as values to empty object; `buildArr` ignores first part of tuple and just write `Foreign`s to empty array, `buildSeries` takes first part of tuple and write it as `\"type\"` field to the second part (`Tuple \"foo\" $ toForeign {a: 12} -\u003e toForeign {\"type\": \"foo\", a: 12}`) and then put it to empty array.\n* There are row names that differs with field names from __echarts__ docs. For example, __echarts__ uses `data` field and `purescript-echarts` uses `items`. Other thing is that some field names collide and to fix it there are new row names: `normalItemStyle`, `normalLabel`.\n* In this approach one could add new type for some field value (like `PercentOrPixel`) _OR_ add command (like `leftCenter`) _OR_ add new `DSL` for building foreign data (like `addItem`).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslamdata%2Fpurescript-echarts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslamdata%2Fpurescript-echarts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslamdata%2Fpurescript-echarts/lists"}