ftlabs/fastclick ? reverse-engineered prompt
Reverse engineered prompt
Build me a small JavaScript library that makes taps on mobile feel instant by removing the usual 300 millisecond click delay. It should work by attaching to the page, usually on the body, and it should fire a normal click right away when someone taps, while avoiding duplicate clicks from the browser. Please include a simple way to ignore certain elements when they need the browser’s real click, like inputs or dropdowns, and make sure it does nothing on desktop browsers or in cases where modern browsers already handle tap response well.
I’d also like a few simple demo pages showing basic usage, focusing an input from a click, and how to handle elements that should not be fast clicked. If there’s a build step for producing a minified version, include that too. Keep the code easy to drop into an existing site, and if you need to check current browser behavior or build tooling details, look up the latest docs online.
Are you gonna build this?
make sure you review the code using coderabbit