This page compares the source lines of code (SLOC) of chartjs/Chart.js and d3/d3 using cached OctoCounts reports. Code size is not code quality: a larger count only means more source material, not a better or worse project.
As of 2026-08-26, chartjs/Chart.js contains 42,350 total lines (31,657 code) across 113 files, while d3/d3 contains 2,512 total lines (871 code) across 8 files as of 2026-08-26. chartjs/Chart.js is about 36x the size of d3/d3 by code lines. Code size is not code quality: a larger count only means more source material, not a better or worse project.
| Metric | chartjs/Chart.js | d3/d3 |
|---|---|---|
| Files | 113 | 8 |
| Total lines | 42,350 | 2,512 |
| Code lines | 31,657 | 871 |
| Comment lines | 5,415 | 1,178 |
| Blank lines | 5,278 | 463 |
| Languages counted | 7 | 4 |
Top languages in chartjs/Chart.js: YAML (48.2% of code), JavaScript (35.9% of code), TypeScript (14.9% of code). Top languages in d3/d3: Shell (78.8% of code), JavaScript (10.7% of code), JSON (10.6% of code). JavaScript, JSON, Shell appear in both top language lists; YAML, TypeScript appear only in chartjs/Chart.js's top languages; Markdown appears only in d3/d3's top languages.
Methodology: both counts come from cached OctoCounts reports generated with tokei. chartjs/Chart.js was counted at ref master (commit cb02e1d207bd) on 2026-08-26; d3/d3 was counted at ref main (commit ca958d45217b) on 2026-08-26. See the counting methodology for ignored directories and analysis options.
Evidence and next steps:
Note: code size is not code quality. OctoCounts only reports reproducible line counts and makes no claim that either project is better.
chartjs/Chart.js has more code: 31,657 code lines versus 871 for d3/d3, about 36x as much, based on cached OctoCounts reports as of 2026-08-26.
Not necessarily. SLOC measures size, not complexity, quality, or maintainability. A larger codebase can mean more features, more generated or vendored code, more verbose language idioms, or more tests — none of which imply the code is harder to work with. Use SLOC to gauge the scale of what you'd be reading or maintaining, not as a quality signal for chartjs/Chart.js, d3/d3, or any repository.
Methodology: both counts come from cached OctoCounts reports generated with tokei. chartjs/Chart.js was counted at ref master (commit cb02e1d207bd) on 2026-08-26; d3/d3 was counted at ref main (commit ca958d45217b) on 2026-08-26. See the counting methodology for ignored directories and analysis options.
Yes. This page shows the default branch for each repository. Use the interactive comparison tool to pick any public GitHub repository, branch, tag, or commit SHA for both sides and get a fresh side-by-side report.