The current jsdom environment does not properly model a browser and lacks various other features that would be nice to have in playwright (see this comment). We should extract E2E tests to their own package and switch to playwright as a best practice.