Basic settings

When you extend StaticPage you get support for a static HTML page.
For basic settings you can override def staticSiteSettings. It has the following fields:

NameMandatoryTypeDefault valueDescription
indexPageNoOption[StaticPage]NoneHome page
mainPagesNoList[StaticPage]List.emptyPages to display in navbar

You usually define it in a common trait, for example:

package utils
import Bundle.*

trait MyStaticPageTemplate extends StaticPage {
  override def staticSiteSettings = super.staticSiteSettings
    .withIndexPage(files.Index)
}

Example of a page definition:

package files
import utils.*
import Bundle.*. Tags.*

object Index extends MyStaticPageTemplate {
  override def mainContent = div("content here")
}

You can get a relative link to Index page with the ref method.
E.g. if you have another page in files.posts package, Index.ref will give you a string "../index.html"