Simple JS To Table Generator – maketable.js

Category: Javascript , Table | November 20, 2023
Author:satsuki-thyme
Views Total:154 views
Official Page:Go to website
Last Update:November 20, 2023
License:MIT

Preview:

Simple JS To Table Generator – maketable.js

Description:

If you’re a developer, you know how important tables are when it comes to presenting data on a website. However, creating tables manually can be a time-consuming task.

That’s where maketable.js comes in, a dead simple JS to Table generator that easily transforms your JavaScript arrays into an organized table.

How to use it:

1. Download and import the maketable.min.js.

<script src="maketable.js"></script>

2. prepare your Thead & Tbody data in JS arrays.

let sourceOfThead = ["a", "b", "c"]
let sourceOfTbody = [
    [0, 1, 2],
    [3, 4, 5]
]

3. Generate an HTML table from the data you just provided.

maketable([sourceOfTbody, sourceOfThead], ["table-id", "table-class"])

Changelog:

11/20/2023

  • Bugfix

You Might Be Interested In:


Leave a Reply