diff --git a/.gitignore b/.gitignore index 9c57edb..b130283 100644 --- a/.gitignore +++ b/.gitignore @@ -21,3 +21,4 @@ lib .xunit coverage .nyc_output +/dist/ diff --git a/package.json b/package.json index d2db8c2..0f1da0d 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "author": "", "license": "ISC", "dependencies": { - "sealious": "^0.13.0" + "sealious": "^0.13.2" }, "devDependencies": { "prettier": "^2.2.1", diff --git a/src/index.ts b/src/index.ts index fa25dd9..c07b051 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,8 +1,16 @@ -import { resolve } from "path"; -import { App, Collection, FieldTypes, Policies } from "sealious"; import _locreq from "locreq"; +import { resolve } from "path"; +import Sealious, { App, Collection, FieldTypes, Policies } from "sealious"; const locreq = _locreq(__dirname); +declare module "koa" { + interface BaseContext { + $context: Sealious.Context; + $app: Sealious.App; + $body: Record; + } +} + const app = new (class extends App { config = { upload_path: locreq.resolve("uploaded_files"),