@cfworker/web 1.13.0 → 1.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/context.d.ts CHANGED
@@ -2,14 +2,14 @@ import { Cookies } from './cookies.js';
2
2
  import { Req } from './req.js';
3
3
  import { ResponseBuilder } from './response-builder.js';
4
4
  export declare class Context {
5
- readonly env: any;
5
+ readonly environmentBindings: any;
6
6
  private readonly _context;
7
7
  readonly req: Req;
8
8
  readonly res: ResponseBuilder;
9
9
  readonly cookies: Cookies;
10
10
  readonly state: any;
11
11
  static fromFetchEvent(event: FetchEvent): Context;
12
- constructor(request: Request, env: any, _context: {
12
+ constructor(request: Request, environmentBindings: any, _context: {
13
13
  waitUntil(promise: Promise<any>): void;
14
14
  });
15
15
  waitUntil(promise: Promise<any>): void;
package/dist/context.js CHANGED
@@ -2,8 +2,8 @@ import { Cookies } from './cookies.js';
2
2
  import { Req } from './req.js';
3
3
  import { ResponseBuilder } from './response-builder.js';
4
4
  export class Context {
5
- constructor(request, env, _context) {
6
- this.env = env;
5
+ constructor(request, environmentBindings, _context) {
6
+ this.environmentBindings = environmentBindings;
7
7
  this._context = _context;
8
8
  this.req = new Req(request);
9
9
  this.res = new ResponseBuilder();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cfworker/web",
3
- "version": "1.13.0",
3
+ "version": "1.14.0",
4
4
  "description": "Web framework for Cloudflare Workers and service workers, inspired by Koa and fastify",
5
5
  "keywords": [
6
6
  "middleware",
package/src/context.ts CHANGED
@@ -16,7 +16,7 @@ export class Context {
16
16
 
17
17
  constructor(
18
18
  request: Request,
19
- public readonly env: any,
19
+ public readonly environmentBindings: any,
20
20
  private readonly _context: {
21
21
  waitUntil(promise: Promise<any>): void;
22
22
  }