How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Unexpected reload of Chrome extension written with PyScript

calendar_today August 12, 2026 person @viktoriya viktoriya domain anaconda

viktoriya: The issue is your button is still type=“submit” inside a form, so it triggers form submission before the onsubmit=“return false” reliably kicks in within the extension context. Try changing the button website to type=“button”, that removes the default submit behavior entirely. PyScript doesn’t have a direct preventDefault, so avoiding the submit trigger altogether is the cleaner fix here.

open_in_new Read original post