page
these are used to serve content to the user.
to create a page, use lib.body.page.new()
.
functions
page.new()
- this creates a new page object.
page(headers)
- you can create a
headers
object usinglib.response.headers.new()
. - this returns the page object, which is useful for chaining.
page(destination, item)
destination
can either be "head" or "body".- if
destination
is "head", thenitem
should be from thelib.head
category. - otherwise, if
destination
is "body", thenitem
should be from thelib.body
category. - this returns the page object, which is useful for chaining.
page(port)
port
is an optional number. it defaults to 8080.- this returns the page object, which is useful for chaining.