setEndpoint static method

void setEndpoint(
  1. String? origin
)

Puts the provided String to the browser's local storage as the origin.

Implementation

static void setEndpoint(String? origin) {
  if (origin == null) {
    web.window.localStorage.removeItem('endpoint');
  } else {
    web.window.localStorage.setItem('endpoint', origin);
  }
}