Closed tbrlpld closed 3 years ago
Whoops. Guess I did not read the template quite right. It uses the attribute extraction syntax const { page } = data.wagtail
which should correctly extract the attribute data.wagtail.page
into the variable page
.
Sorry, my bad 😓
Before, the template example was defining to extract the page data with
const page = data.wagtail
. This leads to the following use of{page.title}
having the valueundefined
.This issue is caused by a missing level in the returned data. The page data is not available at
data.wagtail
but at
data.wagtail.page
.The template example is updated and should display the page title as expected in an
h1
tag.