-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert the library to use Signals and reactive elements #2075
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Size Change: +11.1 kB (+28.1%) 🚨 Total Size: 50.7 kB
|
Awesome! :) We should optimise the new components to reduce the bundle size. Looks great overall. |
this: Hint, | ||
hintElement: HTMLElement, | ||
item: HintItem, | ||
stepId: number |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a backward incompatible change and should be announced.
|
||
const root = div( | ||
{ | ||
className: "introjs-tour", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be great to colocate the classNames, too
if (step >= this._currentStep) { | ||
if ( | ||
this._currentStepSignal.val === undefined || | ||
step >= this._currentStepSignal.val |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use this.getCurrentStep()?
This PR updates the entire library to use Signals and reactive elements as opposed to manually managing the DOM elements. This would help eliminate some of the existing bugs and also make the library much easier to maintain long-term.
Here is the gist of the changes: