Modules@robinpath/csv

@robinpath/csv

0.1.1Public

Parse and stringify CSV data

@robinpath/csv

Parse and stringify CSV data

Category Functions Auth License

Why use this module?

The csv module lets you:

  • Parse a CSV string into an array of objects (first row = headers)
  • Convert an array of objects into a CSV string
  • Extract header names from a CSV string
  • Extract all values from a specific column
  • Parse a CSV string into an array of arrays (raw, no header mapping)

All functions are callable directly from RobinPath scripts with a simple, consistent API.

Installation

npm install @robinpath/csv

Quick Start

No credentials needed — start using it right away:

csv.stringify $data

Available Functions

FunctionDescription
csv.parseParse a CSV string into an array of objects (first row = headers)
csv.stringifyConvert an array of objects into a CSV string
csv.headersExtract header names from a CSV string
csv.columnExtract all values from a specific column
csv.rowsParse a CSV string into an array of arrays (raw, no header mapping)

Examples

Convert an array of objects into a CSV string

csv.stringify $data

Extract header names from a CSV string

csv.headers "name,age\nAlice,30"

Extract all values from a specific column

csv.column "name,age\nAlice,30" "name"

Integration with RobinPath

import { RobinPath } from "@wiredwp/robinpath";
import Module from "@robinpath/csv";

const rp = new RobinPath();
rp.registerModule(Module.name, Module.functions);
rp.registerModuleMeta(Module.name, Module.functionMetadata);

const result = await rp.executeScript(`
  csv.stringify $data
`);

Full API Reference

See MODULE.md for complete documentation including all parameters, return types, error handling, and advanced examples.

Related Modules

License

MIT

Versions (1)

VersionTagPublished
0.1.1latestyesterday
Install
$ robinpath install @robinpath/csv
Version0.1.1
LicenseMIT
Unpacked Size6.1 KB
Versions1
Weekly Downloads0
Total Downloads0
Stars0
Last Publishyesterday
Createdyesterday

Category

utilities