1

I'm currently trying to get ng-joyride to work, but it actually doesn't seem to want to do what I want it to do....

I have the following setup:

HTML:

<!--some content-->
<div class="hide" ng-joy-ride="$ctrl.startJoyRide" config="$ctrl.config" on-finish="$ctrl.onFinish()"  on-skip="$ctrl.onFinish()"></div>

<button type="button" class="btn btn-default" ng-click="$ctrl.test()">Start Joyride</button>

JS:

class Controller {

    constructor() {
        this.config = [
            {
                type: "title",
                heading: "Welcome to the NG-Joyride demo",
                text: '<div class="row"><div id="title-text" class="col-md-12"><span class="main-text">Welcome to <strong>Ng Joyride Demo</strong></span><br><span>( This demo will walk you through the features of Ng-Joyride. )</span><br/><br/><span class="small"><em>This can have custom html too !!!</em></span></div></div>'

            }
        ];
        this.startJoyRide = false;
    }

    test(){
        this.startJoyRide=true;
    }
}

export default Controller;

So I have a config as simple as could be but it's not showing anything at all, when I click on the button...

Also (when clicking the button), I'm getting a error in console, saying $fkEl.size is not a function.

Does anybody see a mistake here, or knows why it's not working?

user5638730
  • 495
  • 2
  • 9
  • 22

1 Answers1

0

This has been noted – but not yet fixed – here: https://github.com/abhikmitra/ng-joyride/issues/67

TL:DR; the dev hasn't yet updated it to jquery 3 yet.

Until he does, you'll have to change the .size() to .length, and make sure you're using an earlier version of jQuery – I'm using 2.2.4 – just downgrading might make the difference.

Good luck!

ghettosoak
  • 319
  • 2
  • 11