src/Router.js
function stateTree(state) {
    if (state.children) state.children = stateTrees(state.children)
    return State(state)
  }
function stateTree(state) {
    if (state.children) state.children = stateTrees(state.children)
    return State(state)
  }
/*
Creates an internal State object from a specification POJO.