{"id":13836530,"url":"https://github.com/eerohele/tab","last_synced_at":"2025-04-09T17:25:24.958Z","repository":{"id":72633234,"uuid":"584538350","full_name":"eerohele/tab","owner":"eerohele","description":"A tool for tabulating Clojure collections.","archived":false,"fork":false,"pushed_at":"2025-04-01T03:45:17.000Z","size":318,"stargazers_count":74,"open_issues_count":7,"forks_count":2,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-04-02T11:53:59.582Z","etag":null,"topics":["clojure","visualization"],"latest_commit_sha":null,"homepage":"","language":"Clojure","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/eerohele.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.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}},"created_at":"2023-01-02T21:20:12.000Z","updated_at":"2024-12-03T07:46:03.000Z","dependencies_parsed_at":"2024-01-04T08:24:02.190Z","dependency_job_id":"c8e9e62f-f1eb-481b-85bc-4d1e18fb7d24","html_url":"https://github.com/eerohele/tab","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eerohele%2Ftab","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eerohele%2Ftab/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eerohele%2Ftab/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eerohele%2Ftab/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eerohele","download_url":"https://codeload.github.com/eerohele/tab/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248075882,"owners_count":21043660,"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":["clojure","visualization"],"created_at":"2024-08-04T15:00:48.634Z","updated_at":"2025-04-09T17:25:24.942Z","avatar_url":"https://github.com/eerohele.png","language":"Clojure","funding_links":[],"categories":["Clojure"],"sub_categories":[],"readme":"# Tab\n\n[![0 dependencies!](https://0dependencies.dev/0dependencies.svg)](https://0dependencies.dev)\n\nTab is a little program that turns Clojure data structures into tables.\n\n\u003cimg width=\"1408\" alt=\"image\" src=\"https://user-images.githubusercontent.com/31859/215182910-f605dc32-b2f3-4bef-be13-4f0ea2331c0a.png\"\u003e\n\n## Rationale\n\nTab's primary aim is to help Clojure programmers make sense of data.\n\nMost interesting Clojure values are maps or seqs of maps. When small, pretty-printing is an adequate tool for inspecting such values. When they get to medium size (like, say, your typical [Ring](https://github.com/ring-clojure/ring) request map), you're better off reaching for something else.\n\nTab aims to be that something else.\n\n## Differences to similar tools\n\n- Tab only shows you one value at a time.\n- Tab datafies (via `clojure.datafy/datafy`) values you give it.\n- Tab aims to be useful without forcing you to choose between different viewers (table, tree, etc).\n- Tab has no dependencies.\n\n## Try\n\nGiven that you have the [Clojure CLI](https://clojure.org/guides/install_clojure) installed, on the command line, run:\n\n```bash\nclj -Sdeps '{:deps {io.github.eerohele/tab {:git/tag \"2024-09-27.371\", :git/sha \"c5d51f4\"}}}'\n```\n\nThen, in the REPL:\n\n```clojure\nuser=\u003e (require 'tab.auto)\nTab is listening on http://localhost:57426\nnil\nuser=\u003e (tap\u003e BigInteger)\ntrue\n```\n\nThen, bask in the glory of the table that appears in your browser. If a tabulated `BigInteger` doesn't do it for you, there are [more examples available](#examples).\n\n\u003e **Note**\n\u003e In general, you'll probably want to use [`tab.api`](#api) instead of `tab.auto`. The only purpose of the `tab.auto` namespace is to make it as easy as possible to run a Tab.\n\nSee the [user manual](#user-manual) for instructions of use.\n\nTo stop Tab:\n\n```clojure\nuser=\u003e (tab.auto/halt)\n```\n\nThe `tab.auto` namespace is the easiest way to run Tab. The `tab.api` namespace exposes the [API](#api) proper.\n\n## API\n\nMost importantly, there's `tab.api/run` and `tab.api/halt`:\n\n```clojure\nuser=\u003e (require '[tab.api :as tab])\nnil\n;; - Run a Tab in port 1234\n;; - Don't open a browser by default.\n;; - Set print length to 8\n;; - Set print level to 2\nuser=\u003e (def tab (tab/run :port 1234 :browse? false :print-length 8 :print-level 2))\n#'user/tab\nuser=\u003e (tab/halt tab)\nnil\n```\n\nSee also:\n\n```clojure\nuser=\u003e (require '[tab.api :as tab])\nnil\nuser=\u003e (doc tab/run)\n...\nuser=\u003e (doc tab/tab\u003e)\n...\nuser=\u003e (doc tab/address)\n...\nuser=\u003e (doc tab/halt)\n...\n```\n\nOnly `tab.api` and `tab.auto` are part of Tab's public API. All other namespaces are internal and subject to change.\n\n## User manual\n\n- Click `-` to collapse a node.\n- Click `+` to expand a node.\n- Press \u003ckbd\u003eAlt\u003c/kbd\u003e and click `-` or `+` to expand or collapse all nodes underneath a node.\n- Click a table header (e.g. `ARRAY MAP`) to zoom in on that table.\n- Press \u003ckbd\u003eAlt\u003c/kbd\u003e and click a table header (e.g. `ARRAY MAP`) to copy the value backing that table to your clipboard.\n- Click opaque objects (`#object[...]`) to view datafied versions of them (provided that they implement `clojure.core.protocols/Datafiable`).\n- Click the text that says `$N vals` in the footer to empty Tab's in-memory database (and release values for garbage collection).\n- Use the buttons in the footer to go to the next/previous value.\n- Click the lightning icon in the footer to pause or resume page updates.\n\n## Examples\n\nFor more examples on what Tab can do, see [`repl/demo/intro.repl`](https://github.com/eerohele/tab/blob/main/repl/demo/intro.repl).\n\n## Features\n\n- Can make tables.\n- Zero dependencies, apart from Clojure itself.\n- [Prefers operating system theme](https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme) (light or dark mode).\n\n## Limitations\n\n- Can only make tables.\n- Will blow up if you expand an infinite seq of scalars in a table cell with an ellipsis.\n- You might be able to have Tab do a denial-of-service attack on itself if you \u003ckbd\u003eAlt\u003c/kbd\u003e-click a node with _many_ children.\n- Requires a modern browser to look good. If your browser supports [`backdrop-filter`](https://developer.mozilla.org/en-US/docs/Web/CSS/backdrop-filter), you should be good.\n- Might not work with Clojure versions older than 1.10.2.\n- Untested on Windows. `:browse? true` [reportedly has no effect on Windows Subsystem for Linux 2, at least](https://github.com/eerohele/tab/issues/1).\n\n## Inspiration\n\n- Gregoire, Daniel. (2018, November 30). [Tables Considered Helpful](https://www.youtube.com/watch?v=b5UK-VHbJlQ) (Clojure/conj 2018).\n\n## Prior art / superior alternatives\n\n- [Morse](https://github.com/nubank/morse)\n- [Portal](https://djblue.github.io/portal/)\n- [Reveal](https://vlaaad.github.io/reveal/)\n\n## Acknowledgements\n\n- [My previous employer](https://www.solita.fi), for graciously sponsoring the development of this tool.\n- [Nikita Prokopov](https://github.com/tonsky), for the [Alabaster Color Scheme](https://github.com/tonsky/sublime-scheme-alabaster).\n- [Pedro Girardi](https://github.com/pedrorgirardi), for alpha testing and improvement ideas.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feerohele%2Ftab","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feerohele%2Ftab","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feerohele%2Ftab/lists"}