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

229
Vistas
Tableau Angular2 Integration

Has anyone tried building an Angular2 application with tableau visualizations integrated in it using the Tableau JavaScript API?

According to the documentation, you're supposed to include the following script in your file which will create a tableau global variable:

<script src="https://YOUR-SERVER/javascripts/api/tableau-2.js"></script>

I'm not sure how to access this global variable within an Angular2 class.

about 4 years ago · Santiago Trujillo
3 Respuestas
Responde la pregunta

0

Im using ng2-admin template and I was able to successfully integrate Tableau and Angular2.

Copy this script <script src="https://YOUR-SERVER/javascripts/api/tableau-2.js"></script> in index.html and paste it within its <body>. Then copy the embed code in any of the components html file within a div.

about 4 years ago · Santiago Trujillo Denunciar

0

declare var tableau: any;

viz: any;//Inside your component class


initViz() {
    const containerDiv = document.getElementById("vizContainer");
    const vizUrl="https://public.tableau.com/views/WorldIndicators/GDPpercapita";
 
    const options = {
      width: containerDiv.offsetWidth,
      height: 600,
      // hideTabs: true,
      // hideToolbar: true,
      onFirstInteractive: function (ev) {
        console.log(ev);
      }
    };
    if(viz != null) { // viz is undefined on both the first and second page loads - even though second page load throws a 'viz already present' error
     viz.dispose();
    }
    var viz = new tableau.Viz(containerDiv, vizUrl,options);
  }
  
  ngOnInit() {    
    this.initViz();
  }

By declaring global variable you can acces it inside component.

about 4 years ago · Santiago Trujillo Denunciar

0

For anyone who wants to embed Tableau visualizations in Angular apps, ngx-tableau provides a simple interface to the Tableau JavaScript API.

It has multiple options for configuring the connection to Tableau Server, handling authentication tickets, adding filters to reports, and managing different sites.

Disclaimer: I am the main contributor to the library.

about 4 years ago · Santiago Trujillo Denunciar
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