The attribute getter returns the previous version of the database.

    The newVersion attribute getter returns the new version of the database, or null if the database is being deleted. See the steps to .

    Events are constructed as defined in Constructing events, in .

    1. Let event be the result of creating an event using .

    2. Set event’s [type](https://www.w3.org/TR/dom41/#dom-event-type) attribute to e.

    3. Set event’s [newVersion](#dom-idbversionchangeevent-newversion) attribute to newVersion.

    4. event at target with legacyOutputDidListenersThrowFlag.

    5. The return value of this algorithm is not always used.