Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Struggling to bootstrap my mashup with a webpack module

I'm migrating my traditional requireJS Angular 1.x mashup to webpack, and struggling to bootstrap it to my module & qlik-angular after qlik has been loaded...

var app = 'app';

module.exports = app;

var baseUrl = 'https://myhub:443/resources';

require('script-loader!./require.js');

window.require.config({baseUrl: baseUrl});

window.require(['js/qlik'], function (qlik) {

  qlik.setOnError(function (error) {

    console.log('Qlik Instance error: [' + error.code + '] ' + error.message);

  });

  // globalQlikInstance = qlik;

  require('angular-ui-router');

  var routesConfig = require('./routes');

  var hello = require('./app/hello');

  angular

  .module(app, ['ui.router'])

  .config(routesConfig)

  .component('app', hello);

  angular.bootstrap(document, ['app', 'qlik-angular']);

}, function (err) {

  console.log('Error loading qlik resources.' + err);

});

I receive an error: App already bootstrapped with this element 'document'

Am I doing something horribly wrong here? I am admittedly new to webpack.

1 Solution

Accepted Solutions
Francis_Kabinoff
Former Employee
Former Employee

Do you have the qva-bootstrap attribute on the html tag set to false?

<!DOCTYPE html>

<html qva-bootstrap="false"> <!--notice the qva-bootstrap="false" attribute-->

  <head>

  </head>

  <body>

  </body>

</html>

View solution in original post

2 Replies
Francis_Kabinoff
Former Employee
Former Employee

Do you have the qva-bootstrap attribute on the html tag set to false?

<!DOCTYPE html>

<html qva-bootstrap="false"> <!--notice the qva-bootstrap="false" attribute-->

  <head>

  </head>

  <body>

  </body>

</html>

Anonymous
Not applicable
Author

Man, that was silly.  Thank you.  Yes I forgot to bring that back in.