support for configuring session saving in localStorage and programmatic base layer definition