Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

238
Vistas
How to resolve PivotTable.js initialization error

I have a project whereby I would like to represent reports using PivotTable.js library. I have done it before and this time I have simply replicated what I did onto this other project, but when I try to render the contents, I get a bunch of errors.

To try to resolve this, I have simplified the render functionality with a small default example with hard-coded data like below:

        try{
            $("#output").pivotUI(
                [
                    {color: "blue", shape: "circle"},
                    {color: "red", shape: "triangle"}
                ],
                {
                    rows: ["color"],
                    cols: ["shape"]
                }
            );
          
        }catch(err){
            console.log(err)
        }

and here are my links in the <head></head> tag:

<link href="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/pivot.css"/>

<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/c3/0.7.20/c3.min.js" ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/7.2.1/d3.min.js" ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/pivot.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/c3_renderers.min.js" ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/d3_renderers.min.js" ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/tips_data.min.js" ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/export_renderers.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pivottable/2.23.0/gchart_renderers.min.js" ></script>

<script src="https://www.gstatic.com/charts/loader.js"></script>

But when I render it returns the following error:

TypeError: $(...).pivotUI is not a function

I have perused all the available links to possible solutions and official docs, but to no avail. I always tend to get one error after the other. I have also tries different version of jQuery but also made not difference. What am I doing wrong?

about 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda