Build a ready-to-dispatch IncomingBrowserEvent for tests.
This is the event a browser application and a React Native one actually receive, and the reason it
has to exist separately from makeIncomingEvent: the React renderer keys its hydration
snapshot on event.fingerprint(), which the platform-agnostic event does not carry. Dispatching
the agnostic one into a rendering application fails with event.fingerprint is not a function,
from inside the kernel's error handler, which says nothing about what is missing.
It lives behind @stone-js/testing/browser so that @stone-js/browser-core is only needed by the
projects that render: a service has no reason to install a browser package to run its tests.
Build a ready-to-dispatch
IncomingBrowserEventfor tests.This is the event a browser application and a React Native one actually receive, and the reason it has to exist separately from makeIncomingEvent: the React renderer keys its hydration snapshot on
event.fingerprint(), which the platform-agnostic event does not carry. Dispatching the agnostic one into a rendering application fails withevent.fingerprint is not a function, from inside the kernel's error handler, which says nothing about what is missing.It lives behind
@stone-js/testing/browserso that@stone-js/browser-coreis only needed by the projects that render: a service has no reason to install a browser package to run its tests.