In "fire an orientation event", it reads:
Fire an event named event at window, using DeviceOrientationEvent, with the alpha attribute initialized to z, the beta attribute initialized to x, the gamma attribute initialized to y, and the absolute attribute initialized to absolute.
However, the event needs to be initialized with DeviceOrientationEventInit instead.
In "fire an orientation event", it reads:
However, the event needs to be initialized with
DeviceOrientationEventInitinstead.