Skip to content

Commit 1af7e77

Browse files
authored
Reorganize badges on README (#1483)
## Changes ### README.md **Badges (lines 3–8):** - Reorganized from 9 badges on a single line to 6 focused badges, each on its own line: npm version, npm downloads, GitHub stars, coverage, Node version, TypeScript - Removed lower-value badges: license (visible in repo sidebar), code style (developer-facing), last commit (redundant with CI table) **CI status table (lines 10–12):** - Renamed headers: `ROS Distro*` → `ROS 2 Distro`, `Status` → `CI Status` - Replaced plain text distro list with a ROS 2 badge showing all supported distros - Stacked CI badges vertically with `<br>` for proportional scaling - Simplified table separator to minimal `| :---: | :---: |` - Removed orphaned footnote note **Intro (line 14):** - Added one-line feature highlights **Performance table (line 246):** - Right-aligned numeric columns for readability ### .prettierignore (new) - Exclude `README.md` and `scripts/npmjs-readme.md` from Prettier auto-formatting to prevent table separator padding from being re-expanded on commit Fix: #1482
1 parent 79ce8fc commit 1af7e77

2 files changed

Lines changed: 22 additions & 13 deletions

File tree

.prettierignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Prettier pads Markdown table separators to match cell width, which bloats
2+
# long-URL badge tables. Exclude root READMEs to keep them minimal.
3+
README.md
4+
scripts/npmjs-readme.md

README.md

Lines changed: 18 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,20 @@
11
# rclnodejs - The ROS 2 Client Library for JavaScript
22

3-
[![npm](https://img.shields.io/npm/v/rclnodejs.svg)](https://www.npmjs.com/package/rclnodejs) [![Coverage Status](https://coveralls.io/repos/github/RobotWebTools/rclnodejs/badge.svg?branch=develop)](https://coveralls.io/github/RobotWebTools/rclnodejs?branch=develop) [![npm](https://img.shields.io/npm/dm/rclnodejs)](https://www.npmjs.com/package/rclnodejs) [![GitHub license](https://img.shields.io/github/license/RobotWebTools/rclnodejs.svg)](https://github.com/RobotWebTools/rclnodejs/blob/develop/LICENSE) [![node](https://img.shields.io/node/v/rclnodejs.svg)](https://nodejs.org/en/download/releases/) [![npm type definitions](https://img.shields.io/npm/types/rclnodejs)](https://www.npmjs.com/package/rclnodejs) [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
3+
[![npm](https://img.shields.io/npm/v/rclnodejs)](https://www.npmjs.com/package/rclnodejs)
4+
[![npm downloads](https://img.shields.io/npm/dm/rclnodejs)](https://www.npmjs.com/package/rclnodejs)
5+
[![GitHub stars](https://img.shields.io/github/stars/RobotWebTools/rclnodejs)](https://github.com/RobotWebTools/rclnodejs/stargazers)
6+
[![Coverage Status](https://coveralls.io/repos/github/RobotWebTools/rclnodejs/badge.svg?branch=develop)](https://coveralls.io/github/RobotWebTools/rclnodejs?branch=develop)
7+
[![node](https://img.shields.io/node/v/rclnodejs)](https://nodejs.org/en/download/releases/)
8+
[![TypeScript](https://img.shields.io/npm/types/rclnodejs)](https://www.npmjs.com/package/rclnodejs)
49

5-
| **ROS Distro\*** | **Status** |
6-
| :----------------------------------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
7-
| Rolling<br>Kilted<br>Jazzy<br>Humble | [![Linux](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-push-test.yml?query=branch%3Adevelop)<br>[![Linux](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-arm64-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-arm64-push-test.yml?query=branch%3Adevelop)<br>[![Windows](https://github.com/RobotWebTools/rclnodejs/actions/workflows/windows-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/windows-push-test.yml?query=branch%3Adevelop)<br>[![ASan](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-asan-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-asan-test.yml?query=branch%3Adevelop) |
8-
9-
> **Note:** Supported ROS 2 distributions include Humble, Jazzy, Kilted, and Rolling.
10+
| **ROS 2 Distro** | **CI Status** |
11+
| :---: | :---: |
12+
| [![ROS 2](https://img.shields.io/badge/ROS%202-Humble%20%7C%20Jazzy%20%7C%20Kilted%20%7C%20Rolling-blue?logo=ros)](https://www.ros.org/) | [![Linux x64](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-push-test.yml?query=branch%3Adevelop)<br>[![Linux arm64](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-arm64-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-arm64-push-test.yml?query=branch%3Adevelop)<br>[![Windows](https://github.com/RobotWebTools/rclnodejs/actions/workflows/windows-push-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/windows-push-test.yml?query=branch%3Adevelop)<br>[![ASan](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-asan-test.yml/badge.svg?branch=develop)](https://github.com/RobotWebTools/rclnodejs/actions/workflows/linux-x64-asan-test.yml?query=branch%3Adevelop) |
1013

1114
**rclnodejs** is a Node.js client library for [ROS 2](https://www.ros.org/) that provides comprehensive JavaScript and TypeScript APIs for developing ROS 2 solutions.
1215

16+
**Key features:** Topics, Services, Actions, Parameters, Lifecycle Nodes, TypeScript support, RxJS Observables, Electron integration, and prebuilt binaries for Linux x64/arm64.
17+
1318
```javascript
1419
const rclnodejs = require('rclnodejs');
1520
rclnodejs.init().then(() => {
@@ -229,15 +234,15 @@ npm run generate-messages-idl
229234

230235
## Performance Benchmarks
231236

232-
Benchmark results for 1000 iterations with 1024KB messages (Ubuntu 24.04.3 WSL2, i7-1185G7):
233-
234-
These numbers are workload- and environment-specific. See [benchmark/README.md](./benchmark/README.md) for the full setup and methodology.
237+
Benchmark results for 1000 iterations with 1024 KB messages (Ubuntu 24.04 WSL2, i7-1185G7):
235238

236239
| Library | Topic (ms) | Service (ms) |
237-
| ----------------------- | ---------- | ------------ |
238-
| **rclcpp (C++)** | 168 | 627 |
239-
| **rclnodejs (Node.js)** | 744 | 927 |
240-
| **rclpy (Python)** | 1,618 | 15,380 |
240+
| ----------------------- | ---------: | -----------: |
241+
| **rclcpp** (C++) | 168 | 627 |
242+
| **rclnodejs** (Node.js) | 744 | 927 |
243+
| **rclpy** (Python) | 1,618 | 15,380 |
244+
245+
These numbers are workload- and environment-specific. See [benchmark/README.md](./benchmark/README.md) for the full setup and methodology.
241246

242247
## Contributing
243248

0 commit comments

Comments
 (0)