Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

JavaScript Example #12

Closed
felixerdy opened this issue Apr 10, 2018 · 2 comments
Closed

JavaScript Example #12

felixerdy opened this issue Apr 10, 2018 · 2 comments

Comments

@felixerdy
Copy link

Could you please provide a JavaScript example code?

I am using your HTML snippet from here and tried to instantiate steps with the following JS code:

let steps = new bulmaSteps('#stepsDemo', {
    onShow: (id) => console.log(id)
})

Unfortunately, I get the following error: Uncaught TypeError: a.querySelectorAll is not a function

@felixerdy
Copy link
Author

felixerdy commented Apr 10, 2018

Okay, I just found the solution by myself:

new bulmaSteps(document.getElementById('stepsDemo'), {
    onShow: (id) => console.log(id)
})

@AngelTorres96
Copy link

@felixerdy Hi, could you please explain me how it works this line? onShow:(id)=>console.log(id), i don't understand the id parameter

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants