Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shevabam/htmlify-csv
Converts a CSV file into an HTML table very easily!
https://github.com/shevabam/htmlify-csv
csv html table
Last synced: 2 months ago
JSON representation
Converts a CSV file into an HTML table very easily!
- Host: GitHub
- URL: https://github.com/shevabam/htmlify-csv
- Owner: shevabam
- License: mit
- Created: 2017-10-20T09:46:02.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2021-03-10T08:39:05.000Z (almost 4 years ago)
- Last Synced: 2024-10-29T06:07:00.708Z (2 months ago)
- Topics: csv, html, table
- Language: CSS
- Size: 104 KB
- Stars: 9
- Watchers: 3
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# htmlify-csv.js
This NodeJs module converts a CSV file into an HTML table very easily!
The HTML table generated allows you to filter the columns and sort them.
![](sample/htmlify-csv_example.png)
## Install
Clone this repository:
```
git clone [email protected]:shevabam/htmlify-csv.git
cd htmlify-csv
```Then run:
```
npm install
```## Usage
Converts `example.csv` into HTML file, located in `datas` folder:
```
node htmlify-csv convert example.csv
```Add some options to define the delimiter and to open the generated HTML file in your Web browser:
```
node htmlify-csv convert example.csv --delimiter=";" --show
```Converts `datas/example.csv` to `datas/example.html` width ";" delimiter, and open output file in your Web browser:
```
node htmlify-csv convert "datas/example.csv" --delimiter=";" --output="datas/example.html" --show
```## Options
To view all available options, use:
```
node htmlify-csv --help
```| Param | Description | Default | Example |
| --- | --- | --- | --- |
| --delimiter | CSV delimiter | , | --delimiter=";" |
| --output | Output filename | datas/output.html | --output="file.html" |
| --show | Open HTML output file in browser | false | |
| --port | Server port number | 8090 | --port=1337## Credits
* [jQuery](https://jquery.com/)
* [tablesorter](https://mottie.github.io/tablesorter/docs/)
* [Caporal.js](https://github.com/mattallty/Caporal.js)
* [babyparse](https://www.npmjs.com/package/babyparse)