Skip to content
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

Allow Passing Elements to Start Method #7

Open
MakanaMakesStuff opened this issue Jun 13, 2022 · 0 comments
Open

Allow Passing Elements to Start Method #7

MakanaMakesStuff opened this issue Jun 13, 2022 · 0 comments

Comments

@MakanaMakesStuff
Copy link
Owner

MakanaMakesStuff commented Jun 13, 2022

It would be valuable to extend the start method of our plugin to allow Elements as an argument instead of just passing a string selector. This is mainly because we might want to separate the implementation of the plugin from us accessing DOM elements, which would let us have more control over the logical flow of our code. For example, we can select the element from the dom when the page loads and simply pass it to our start method when we need to as opposed to selecting the elements at the time of our method call. This is not necessarily a bad thing, but we would have to do some weird things or alter our plugin code if we wanted to handle a dom element at all before calling the start method.

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

No branches or pull requests

1 participant