JSFiddle - React, Tailwind, and code Playground

by Flexmonster Pivot Table

HTML

<link rel="stylesheet" href="https://s3.amazonaws.com/flexmonster/2.3/demo.css">
<script src="https://cdn.flexmonster.com/flexmonster.js"></script>

<div id="pivot-container"></div>

JavaScript

const pivot = new Flexmonster({
  container: "pivot-container",
  componentFolder: "https://cdn.flexmonster.com/",
  toolbar: true,
});

pivot.on("reportcomplete", function() {
  pivot.off("reportcomplete");
  pivot.setReport({
    "dataSource": {
      "type": "json",
      "data": getData(),
      "mapping": {
        "CPF / CNPJ do cliente": {
          "type": "string"
        },
        "Nome do cliente": {
          "type": "string"
        },
        "Telefone cliente": {
          "type": "string"
        },
        "Data de cadastro": {
          "type": "date string"
        },
        "Número contrato": {
          "type": "string"
        },
        "Data vigencia do contrato": {
          "type": "date string"
        },
        "Gerente": {
          "type": "string"
        },
        "Risco": {
          "type": "string"
        },
        "Limite credito": {
          "type": "string"
        },
        "Tipo de pessoa": {
          "type": "string"
        },
        "Nome fantasia": {
          "type": "string"
        },
        "Data de abertura": {
          "type": "date string"
        },
        "Data de nascimento": {
          "type": "date string"
        },
        "Inscrição municipal": {
          "type": "string"
        },
        "Inscrição estadual": {
          "type": "string"
        },
        "Estado civil": {
          "type": "string"
        },
        "Identidade": {
          "type": "string"
        },
        "Orgão expedidor": {
          "type": "string"
        },
        "Nacionalidade": {
          "type": "string"
        },
        "Naturalidade": {
          "type": "string"
        },
        "Simples nacional": {
          "type": "string"
        },
        "Operação": {
          "type": "number"
        },
        "IOF mensal a recolher": {
          "type": "number"
        },
        "Tipo Operação": {
          "type": "string"
        },
        "Data operação": {
          "type": "date string"
    ...