@lwrjs/server 0.7.0-alpha.2 → 0.7.0-alpha.6

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.
@@ -33,6 +33,9 @@ var ExpressRequest = class {
33
33
  get method() {
34
34
  return this.req.method;
35
35
  }
36
+ get headers() {
37
+ return this.req.headers;
38
+ }
36
39
  get protocol() {
37
40
  return this.req.protocol;
38
41
  }
@@ -36,6 +36,9 @@ var KoaRequest = class {
36
36
  get method() {
37
37
  return this.ctx.method;
38
38
  }
39
+ get headers() {
40
+ return this.ctx.headers;
41
+ }
39
42
  get locale() {
40
43
  return this.ctx.locale;
41
44
  }
@@ -1,5 +1,5 @@
1
1
  import { Request } from 'express';
2
- import { RuntimeContext, RuntimeEnvironment, MiddlewareRequest } from '@lwrjs/types';
2
+ import { RuntimeContext, RuntimeEnvironment, MiddlewareRequest, Headers } from '@lwrjs/types';
3
3
  export default class ExpressRequest implements MiddlewareRequest {
4
4
  private req;
5
5
  isMetadataRequest: boolean;
@@ -10,6 +10,7 @@ export default class ExpressRequest implements MiddlewareRequest {
10
10
  get query(): any;
11
11
  get body(): any;
12
12
  get method(): string;
13
+ get headers(): Headers;
13
14
  get protocol(): any;
14
15
  get locale(): string;
15
16
  set locale(l: string);
@@ -22,6 +22,9 @@ export default class ExpressRequest {
22
22
  get method() {
23
23
  return this.req.method;
24
24
  }
25
+ get headers() {
26
+ return this.req.headers;
27
+ }
25
28
  get protocol() {
26
29
  return this.req.protocol;
27
30
  }
@@ -1,5 +1,5 @@
1
1
  import Koa from 'koa';
2
- import { RuntimeContext, RuntimeEnvironment, MiddlewareRequest } from '@lwrjs/types';
2
+ import { RuntimeContext, RuntimeEnvironment, MiddlewareRequest, Headers } from '@lwrjs/types';
3
3
  export default class KoaRequest implements MiddlewareRequest {
4
4
  protected ctx: Koa.Context;
5
5
  isMetadataRequest: boolean;
@@ -11,6 +11,7 @@ export default class KoaRequest implements MiddlewareRequest {
11
11
  get protocol(): any;
12
12
  get body(): any;
13
13
  get method(): string;
14
+ get headers(): Headers;
14
15
  get locale(): string;
15
16
  set locale(l: string);
16
17
  isSiteGeneration(): boolean;
@@ -24,6 +24,9 @@ export default class KoaRequest {
24
24
  get method() {
25
25
  return this.ctx.method;
26
26
  }
27
+ get headers() {
28
+ return this.ctx.headers;
29
+ }
27
30
  get locale() {
28
31
  return this.ctx.locale;
29
32
  }
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.7.0-alpha.2",
7
+ "version": "0.7.0-alpha.6",
8
8
  "homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
9
9
  "repository": {
10
10
  "type": "git",
@@ -30,7 +30,7 @@
30
30
  "build/**/*.d.ts"
31
31
  ],
32
32
  "devDependencies": {
33
- "@lwrjs/types": "0.7.0-alpha.2",
33
+ "@lwrjs/types": "0.7.0-alpha.6",
34
34
  "@types/koa-compress": "^4.0.1",
35
35
  "@types/koa__router": "^8.0.4",
36
36
  "@types/spdy": "^3.4.4",
@@ -38,7 +38,7 @@
38
38
  },
39
39
  "dependencies": {
40
40
  "@koa/router": "^10.0.0",
41
- "@lwrjs/shared-utils": "0.7.0-alpha.2",
41
+ "@lwrjs/shared-utils": "0.7.0-alpha.6",
42
42
  "@types/compression": "^1.7.2",
43
43
  "@types/express": "^4.17.11",
44
44
  "@types/koa": "^2.11.7",
@@ -55,5 +55,5 @@
55
55
  "engines": {
56
56
  "node": ">=14.15.4 <17"
57
57
  },
58
- "gitHead": "fc3a13d1c5440833eb2ec17fbf0e294554bafa08"
58
+ "gitHead": "d536e1f978f13c4fa171b5f643f61a876e746da0"
59
59
  }