<||= if not? all? @[2 = size pagePath "documentation" = first pagePath "_index" = last pagePath][ ||>
  • Home
  • <|| ] ||> <||= pathItems: new [] pathSoFar: new ["documentation"] pageRoute: new pagePath if "_index" = last pageRoute -> pageRoute: chop pageRoute pageRoute: slice pageRoute 1 (size pageRoute)-1 loop.with:'pidx pageRoute 'pp [ 'pathSoFar ++ pp if? pp=last pageRoute [ lastItem: pp if not? and? [contains? pageRoute "library"] [and? [0 =< pidx-2]["library"= pageRoute\[pidx-2]]] [ lastItem: join.with:" " map split.words lastItem 'x -> capitalize replace x "-" "?" ] 'pathItems ++ ~{
  • |replace lastItem "-" "?"|
  • } ] else [ 'pathItems ++ ~{
  • |capitalize pp|
  • } ] ] join pathItems ||> <||= if key? W 'source [ ~{
  •   Source
  • }] ||>