Today we are starting a new series of tutorials, but with a twist. We are leaving Alpinejs behind and instead using vainilla JavaScript to create our components.
For further actions, you may consider blocking this person and/or reporting abuse
Today we are starting a new series of tutorials, but with a twist. We are leaving Alpinejs behind and instead using vainilla JavaScript to create our components.
For further actions, you may consider blocking this person and/or reporting abuse
Anwer Solangi -
Adrián Bailador -
Phaustin Karani -
Probir Sarkar -
Top comments (5)
Your use cases confuse me -
That sounds fine!
I don't think it's likely people would be using their cart in a manner where the page is long enough for this to matter, and the position on the page is likely irrelevant since most carts put their main CTA at the top.
This is the same as the Content marketing case.
People don't use progress indicators for social media feeds because they are typically infinite scroll and the bar will jump back and forth a lot as you read!
My suggestion would be to inject the element with Javascript in the first place rather than baking it into the HTML, and omitting the Tailwind aspect, which is adding a dependency but not any actual benefit. If you're creating and modifying the element with script, you can add style attributes the same way and keep it entirely separate, so you can inject the progress bar into any page you like with a function call.
Just examples man, don't get it twisted.
Another way to add Scroll Progress Bar in React
nice
Cool