Skip to content
Agents tracked: 440 Downloads (7d): 202M down 19.5% GitHub stars: 10.4M Releases (7d): 607 Agent status: 1 with issuesSince last limit reset: Claude 28d · Codex 0d Updated Oct 21, 2026

SheetJS Examples You Can Edit and Run

5 small SheetJS examples written by AgentGid from the official docs, one feature each. Every one runs in your browser: change the code and see the result at once, or describe a change and let AI rewrite it. The screenshots are taken from the same code by our server, which also checks that each example starts without errors.

SheetJS: usage and stats 127 AI-built projects use it

Try them all in one place

import * as XLSX from "xlsx";

// Dark page styles
const css = document.createElement("style");
css.textContent = `
  body { margin: 0; background: #111; }
  #root { font: 14px system-ui, sans-serif; color: #e5e7eb; padding: 20px; box-sizing: border-box; }
  h3 { margin: 0 0 10px; font-size: 15px; color: #fff; }
  table { border-collapse: collapse; background: #1c1c1c; }
  td, th { border: 1px solid #3a3a3a; padding: 6px 12px; text-align: left; }
  tr:first-child td { background: #2a2a2a; font-weight: 600; color: #fff; }
`;
document.head.appendChild(css);

const rows = [
  { Name: "Ada Lovelace", Team: "Research", Score: 92 },
  { Name: "Grace Hopper", Team: "Compilers", Score: 88 },
  { Name: "Alan Turing", Team: "Research", Score: 95 },
  { Name: "Katherine Johnson", Team: "Orbits", Score: 90 },
];

// Array of objects -> worksheet; the object keys become the header row
const ws = XLSX.utils.json_to_sheet(rows);

// Put the worksheet in a new workbook under the name "Team"
const wb = XLSX.utils.book_new();
XLSX.utils.book_append_sheet(wb, ws, "Team");

// Render the sheet back as an HTML table
const root = document.getElementById("root");
root.innerHTML =
  `<h3>Sheets: ${wb.SheetNames.join(", ")} &middot; range ${ws["!ref"]}</h3>` +
  XLSX.utils.sheet_to_html(ws, { id: "team" });
Ctrl/⌘ + Enter runs

Free for signed-in members, with a daily limit. Describe the change in plain words; the new code runs only in your browser.

Add a new key such as City to the first object and a new column appears in the table. Code written by AgentGid [1]. How it works, with a screenshot →

Checked Oct 12, 2026: each example starts without errors in Chromium with xlsx 0.18.5. Needs WebGL.

Sources

  1. Docs: docs › api › utilities › array
  2. Docs: docs › getting-started › examples › export
  3. Docs: docs › api › utilities › html
  4. Docs: docs › api › write-options

Explanations written by AgentGid from the official docs; the numbers in brackets point here. The code marked "written by AgentGid" is ours and free to copy.

Building something with SheetJS? Ask AgentGid →