Property 'params' does not exist on type 'Context<State, Record<string, any>> ... what to do?
I want to access params in oak, but typescript complains.
What can I do about that?
Thanks.
What can I do about that?
Thanks.
class CityController {
async createCity(context: Context) {
const { citySlug } = context.params
const key = ['cities', citySlug]
const result = await kv.atomic().check({ key, versionstamp: null }).set(key, value).commit()
}
...
}const query_params: Record<string, string> = helpers.getQuery(context, { mergeParams: true });