# @markuplint/html-spec

> A specification of HTML Living Standard for markuplint

Latest version **5.3.0** (published 2026-10-21) · MIT license · 0 weekly downloads

## Install

```sh
npm install @markuplint/html-spec
pnpm add @markuplint/html-spec
yarn add @markuplint/html-spec
bun add @markuplint/html-spec
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; recently updated; high maintenance score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 5.3.0 |
| Published | 2026-10-21 |
| First published | 2020-07-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=24 |
| Dependencies | 1 |
| Unpacked size | 1.9 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 624 |
| Author | Yusuke Hirao |
| Maintainers | yusukehirao |

## Links

- npm: https://www.npmjs.com/package/@markuplint/html-spec
- Repository: https://github.com/markuplint/markuplint
- Homepage: https://github.com/markuplint/markuplint#readme
- Issues: https://github.com/markuplint/markuplint/issues
- npm.io page: https://npm.io/package/@markuplint/html-spec

## Dependencies (1)

- [@markuplint/ml-spec](https://npm.io/package/@markuplint/ml-spec.md) 5.3.0

## Recent versions

- 5.3.0 (latest) — 2026-10-21
- 4.18.4 (v4) — 2026-10-22
- 5.0.0-rc.7 (rc) — 2026-08-31
- 5.0.0-rc.1 (next) — 2026-03-27
- 5.0.0-dev.5 (canary) — 2026-02-27
- 3.0.0-alpha.27 (dev) — 2022-12-20
- 5.2.0 — 2026-10-13
- 5.1.1 — 2026-10-09
- 5.1.0 — 2026-10-08
- 5.0.1 — 2026-09-22
- 5.0.0 — 2026-09-11
- 5.0.0-rc.6 — 2026-08-30
- 5.0.0-rc.5 — 2026-08-29
- 4.18.0 — 2026-04-22
- 5.0.0-rc.4 — 2026-04-19
- … 176 more at https://npm.io/package/@markuplint/html-spec/versions

## README

# @markuplint/html-spec

[![npm version](https://badge.fury.io/js/%40markuplint%2Fhtml-spec.svg)](https://www.npmjs.com/package/@markuplint/html-spec)

**Canonical HTML Living Standard dataset provider with automated external data enrichment.**

This package provides the consolidated HTML element specification data for markuplint, including:

- **HTML Living Standard elements** with complete attribute definitions
- **WAI-ARIA mappings** (implicit roles, permitted roles, ARIA properties)
- **Content model definitions** for each element
- **MDN-enriched metadata** (descriptions, compatibility, experimental status)
- **Automated external data integration** from authoritative sources

This package serves as the data layer in markuplint's specification system, depending on `@markuplint/ml-spec` for type definitions and structural schemas.

## Package Architecture

```
@markuplint/ml-spec (Foundation Layer)
  ↓ provides types, algorithms, schemas
@markuplint/html-spec (Data Layer) ← YOU ARE HERE
  ↓ provides HTML specification data
Framework-specific specs (Extension Layer)
  ↓ provide framework extensions
Core packages (Application Layer)
  ↓ consume specifications for validation
```

## Package Contents

### Generated Output (DO NOT EDIT)

- **`index.json`** - Consolidated specification data (48K+ lines)

### Source Files (EDIT THESE)

- **`src/spec.*.jsonc`** - Individual element specifications (208 files)
- **`src/spec-common.attributes.jsonc`** - Global attribute category definitions (20 categories)
- **`src/spec-common.contents.jsonc`** - Content model category macros (HTML 10 + SVG 19 + MathML 3 categories)

### Build System

- **`build.ts`** - Generation script that invokes `generator/` modules
- Fetches live data from MDN, W3C ARIA specs, Graphics ARIA, DPub ARIA, HTML-ARIA mappings, HTML Living Standard, SVG specs, and MathML specs

## Relationship to @markuplint/ml-spec

**@markuplint/ml-spec** provides the foundation:

- **Type definitions** (`ElementSpec`, `ExtendedSpec`, `MLMLSpec`) that structure this data
- **JSON schemas** that validate the specification format
- **Algorithms** that process and compute values from this specification data

**@markuplint/html-spec** (this package) provides:

- **Canonical HTML data** following the type definitions from `@markuplint/ml-spec`
- **External data enrichment** from MDN and W3C specifications
- **Build automation** that keeps data synchronized with external sources

## Install

[`markuplint`](https://www.npmjs.com/package/markuplint) package includes this package.

<details>
<summary>If you are installing purposely, how below:</summary>

```shell
$ npm install @markuplint/html-spec

$ yarn add @markuplint/html-spec
```

</details>

## Contributing

## License

MIT

---
_Source: https://npm.io/package/@markuplint/html-spec · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
