Skip to content

Lightweight Tables via JSON Specs and JavaScript

1packages dependsuggested by 1
1.5Kdownloads / year
–test coverage
13/13flavors OK

Overview

About

A lightweight grammar of tables. Build a table by declaring a JSON spec (titles, spanners, row groups, footnotes, formatting functions, etc.); a tiny vanilla JavaScript runtime builds the HTML table from the spec on page load. Cells can hold inline plots (error bars, dot plots, mini line and bar charts) drawn as SVG in the browser from the numbers alone. Tables can optionally be made interactive (sorting, searching, filtering, pagination, column hiding, expandable row detail, and CSV download) via a separate extension loaded only when requested. No 'sass', no 'V8', no 'htmlwidgets' — just base R and 'xfun' ('htmltools' is used only for the optional Shiny binding and for embedding tables in other HTML output).

Changes in 0.5
  • Added lt_interactive() to make a table interactive in the browser: click-to-sort headers, a search box, per-column filters (plain, or typed dropdown/range/checklist widgets), pagination, column resizing, a column-visibility menu, expandable row detail, and a CSV download of the current view. Everything runs client-side via an extension loaded only for opted-in tables, and sorting and filtering stay within each row group or subtree.
  • Added lt_errorbar(), lt_sparkline(), and lt_dotplot() to draw lightweight inline plots (error bars, line/bar sparklines, dot plots) in table cells: only the numbers travel to the client and the SVG is drawn in the browser.
  • Interactive tables expose a controller el._lt for driving filters and row detail from external widgets, plus LT.ui helpers (popover(), checklist(), chip()) and a new LT.render(el, spec) for building such widgets and on-demand tables.
  • Column selection now accepts predicate formulas referencing the pronoun . (the column names), e.g. ~ endsWith(., "_time"), in all functions that select columns.
  • lt_label() now also accepts a named list or vector mapping column names to labels.
  • Added lt_wrap() to set HTML attributes on the .lt-wrap container, a hook for scoping custom CSS or sizing a table.
  • lt_spanner() no longer requires its columns in visual order; they are reordered to match the body before rendering (they must still be contiguous).
  • lt_export() no longer drops a lt_css() stylesheet attached by a relative path (thanks, @tgerke, #7).
  • lt_export() no longer spills a cropped PDF onto a second page when the table height is fractional.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 1.2 min · r-oldrel-windows-x86_64
Status changes
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK6 OK2026-07-01
Advisories

none known

Documentation

In release 0.5
READMEYes · 949 wordsVignettesNoNEWSYes · 100% structured · mentions 0.5Citation fileNo
Help pages
32 (2 internal)includes a package overview page
Examples that run
100%30 run in a plain check (2 of them under a condition)
Exported functions with examples
97%
Documented parameters
98%
Return-value docs
97%
Help pages citing references
0%

Downloads

1.5K
CRAN downloads in the past year
Rank #6,228 · ~4/day · ~129/mo
Daily download trend is not available in this view yet.
53630 days
1.3K90 days
1.5K1 year
Compare downloads with other packages →
Also on119 r2u4 autocran

Repository

27Stars
2Forks
0Open issues
2Open PRs
5Releases
245Commits
2Commit identities
245 commits · Last activity 2026-10-17 · +3.8% stars, 30d
Responsiveness
How these are sampled
PRs merged (all time)
92%
Median days to close, 50 most recently updated closed issues
2
Median days to close, 50 most recently updated closed PRs
0

Stars over time

2026-05-20 · 42026-09-30 · 27
PracticesBeta

5 development-tooling and community-health practices detected across 4 families in the upstream repository

Checks run against github.com/yihui/lt on 2026-10-11.

Continuous integration (2)
GitHub ActionsR CMD check workflow

The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel

Governance and community (1)

The repository owner accepts GitHub Sponsors

Docs source (1)

GitHub Pages site last deployed 2026-10-10

Lint, format, editor (1)
RStudio project
How this is detected·Detection ruleset v3 (2026-09-26)
AI coding toolsBeta

This repository shows signs of AI coding tools.

  • Claude Codefirst seen 2026-05-19
    Seen in the repository: CLAUDE.md
    Named in .Rbuildignore: .claude, CLAUDE.md
    Pull request it wrote: opened by a project member
    Commits: at least 192 crediting it in the message
  • GitHub Copilotfirst seen 2026-06-08
    Pull request: opened by its own account
Models named in its commits
  • Claude Opus 4.687 commits · May to Jul 2026
  • Claude Opus 4.79 commits · May to Jun 2026
  • Claude Opus 4.84 commits · Jun 2026

Some of these counts are a minimum, because the search stopped before the oldest commits.

Counts are commits, not lines of code. Commits by a tool's accounts count once across all of its accounts. Commits crediting it are the largest count among its credit lines, a minimum.How this is detected·Detection ruleset v4 (updated 2026-09-27)

Dependencies

Declared dependencies
9 external dependencies (excludes base and recommended)

Installing lt adds 1 package (1 with compiled code, 224 KB of source tarballs). Heaviest: xfun 224 KB.

Depends (1)
R >= 4.1.0
Imports (2)
grDevicesxfun
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
1direct
1indirect
Imports 1
Suggested by 1
Depends, Imports or LinkingTo, most downloaded first
Suggests, most downloaded first

People & History

People (1)
Author, Maintainer since 0.1 (2026), Copyright holder
https://yihui.org
Releases (5)

Pick two releases to compare their code metrics.

  • 0.5Latest
    record
    2026-10-17 · current release · diff ↗ ·
    added 9 exports
    js, lt_dependency, lt_dotplot, lt_errorbar, lt_hide, lt_interactive, lt_sparkline, lt_spec, lt_wrap
    ·
    listed once in CRAN's queue
    Seen in one reading of CRAN's incoming queue, at 2026-10-17 02:21 UTC, so it stayed less than the time between readings.
  • 0.4
    record
    2026-09-01 · diff ↗
  • 0.3
    record
    2026-08-19 · diff ↗
  • 0.2
    record
    2026-07-09 · diff ↗ ·
    added 2 exports
    lt_export, lt_html
  • 0.1
    record
    2026-06-30
  • R
    R 4.6.0 released · 2026-04-24
Across CRAN, the median accepted release of the past year spent 19 hours in the queue, 90% under 11 days.How queue time is measured

Package metadata

First published
2026-06-30
Total releases
5 / 1 yrs
License
MIT + file LICENSE OSI
Minimum R
≥ 4.1.0
Download size
115 KB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("lt")
Xie, Y. (2026). lt: Lightweight Tables via JSON Specs and JavaScript (Version 0.5) [Computer software]. https://doi.org/10.32614/CRAN.package.lt

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for lt version 0.5 [Data set]. HJJB, LLC. Data release v2026-10-18. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-18, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy