Interface UidlRequestHandler.MprPushStateJs

All Superinterfaces:
Serializable
Enclosing class:
UidlRequestHandler

@JsDefinition public static interface UidlRequestHandler.MprPushStateJs extends Serializable
The push state that the MPR fix-up sends, as a JavaScript definition, so that the build collects it into the bundle and the corrected location is a parameter of the call rather than part of the JavaScript.

For internal use only. May be renamed or removed in a future release.

Since:
25.4
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Pushes the given hash onto the location the browser is at, for a v7 UIDL that named no location to go with it.
    void
    pushLocation(String location)
    Pushes the given location, which the v7 UIDL gave in full.
  • Method Details

    • pushLocation

      @JsExpression("setTimeout(() => history.pushState(null, \'\', $0));") void pushLocation(String location)
      Pushes the given location, which the v7 UIDL gave in full.
      Parameters:
      location - the location to push
    • pushHash

      @JsExpression("setTimeout(() => history.pushState(null, \'\', location.pathname + location.search + \'#\' + $0));") void pushHash(String hash)
      Pushes the given hash onto the location the browser is at, for a v7 UIDL that named no location to go with it.
      Parameters:
      hash - the hash to push, without the leading #