https://github.com/vanillawc/wc-csv-table
A vanilla web component to present CSV as a HTML table
https://github.com/vanillawc/wc-csv-table
csv table vanilla web-components
Last synced: about 1 month ago
JSON representation
A vanilla web component to present CSV as a HTML table
- Host: GitHub
- URL: https://github.com/vanillawc/wc-csv-table
- Owner: vanillawc
- License: mit
- Created: 2019-12-18T23:24:26.000Z (over 6 years ago)
- Default Branch: main
- Last Pushed: 2021-05-15T18:08:39.000Z (almost 5 years ago)
- Last Synced: 2025-11-23T17:03:21.895Z (4 months ago)
- Topics: csv, table, vanilla, web-components
- Language: JavaScript
- Size: 77.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
<wc-csv-table> CSV -> HTML Table
## Installation
*Installation*
```sh
npm i @vanillawc/wc-csv-table
```
*Import from NPM*
```html
```
*Import from CDN*
```html
```
## Demo
Try it on [WebComponents.dev](https://webcomponents.dev/edit/e9ymso9FS3XKUVomG90u?sv=1&pm=1)
## Usage
**Attributes**
- `src` - load an external CSV file
- `no-headers` - there is no header row
**Properties**
- `value` - get/set the editor's contents
- `noHeaders` - `no-headers` as a property
### Basic Usage
```html
```
### 'no-headers' Attribute
Use `no-headers` if your data doesn't contain row headers
```html
```
## Styling
By default, `` contains an un-styled `` element in the lightDOM. That means, it will inherit any global CSS styles present on the site and can be styled directly using CSS.
## Contributing
See [CONTRIBUTING.md](https://github.com/vanillawc/vanillawc/blob/main/CONTRIBUTING.md)