'use strict' const router = require('koa-router')() router.get('/', async function (ctx, next) { await next() const { title } = ctx.state ctx.body = ` ${title}

${title}

Welcome to ${title}

` }, async (ctx) => ctx.state = {title: 'Koa'}) module.exports = router