altair-express-middleware 4.2.1 → 4.2.2

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.
@@ -1 +1,2 @@
1
1
  export {};
2
+ //# sourceMappingURL=index.d.ts.map
@@ -10,6 +10,18 @@ app.use('/altair', index_1.altairExpress({
10
10
  initialQuery: `{ getData { id name surname } }`,
11
11
  // serveInitialOptionsInSeperateRequest: true,
12
12
  initialPreRequestScript: `console.log('Hello from pre request!')`,
13
+ initialWindows: [
14
+ {
15
+ initialQuery: '{ myFirst }',
16
+ endpointURL: '/test1',
17
+ initialName: 'name me',
18
+ },
19
+ {
20
+ initialQuery: '{ mySecond }',
21
+ endpointURL: '/test2',
22
+ },
23
+ ],
24
+ preserveState: false,
13
25
  }));
14
26
  app.get('/', (req, res) => res.send('Hello world'));
15
27
  app.listen(port, () => console.log(`Example app listening on port ${port}!`));
package/build/index.d.ts CHANGED
@@ -2,3 +2,4 @@
2
2
  import * as express from 'express';
3
3
  import { RenderOptions } from 'altair-static';
4
4
  export declare const altairExpress: (opts: RenderOptions) => express.Express;
5
+ //# sourceMappingURL=index.d.ts.map
package/example/index.ts CHANGED
@@ -10,6 +10,18 @@ app.use('/altair', altairExpress({
10
10
  initialQuery: `{ getData { id name surname } }`,
11
11
  // serveInitialOptionsInSeperateRequest: true,
12
12
  initialPreRequestScript: `console.log('Hello from pre request!')`,
13
+ initialWindows: [
14
+ {
15
+ initialQuery: '{ myFirst }',
16
+ endpointURL: '/test1',
17
+ initialName: 'name me',
18
+ },
19
+ {
20
+ initialQuery: '{ mySecond }',
21
+ endpointURL: '/test2',
22
+ },
23
+ ],
24
+ preserveState: false,
13
25
  }));
14
26
  app.get('/', (req, res) => res.send('Hello world'));
15
27
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "altair-express-middleware",
3
- "version": "4.2.1",
3
+ "version": "4.2.2",
4
4
  "description": "Express middleware for altair graphql client",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "homepage": "https://github.com/altair-graphql/altair#readme",
33
33
  "dependencies": {
34
- "altair-static": "^4.2.1",
34
+ "altair-static": "^4.2.2",
35
35
  "express": "^4.16.2"
36
36
  },
37
37
  "devDependencies": {
@@ -46,5 +46,5 @@
46
46
  "url": "https://opencollective.com/altair",
47
47
  "logo": "https://opencollective.com/altair/logo.txt"
48
48
  },
49
- "gitHead": "d1c9b6c9f6c9d2e3b0d9f0b99cd04573e9bf6439"
49
+ "gitHead": "e2e4d611e12de827ed0a47f09145bbdf4bae291e"
50
50
  }
package/tsconfig.json CHANGED
@@ -3,6 +3,7 @@
3
3
  "outDir": "build/",
4
4
  "rootDir": "./",
5
5
  "declaration": true,
6
+ "declarationMap": true,
6
7
  "target": "es2020",
7
8
  "module": "commonjs",
8
9
  "lib": [