@backstage/plugin-app-backend 0.3.25 → 0.3.28

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/CHANGELOG.md CHANGED
@@ -1,5 +1,31 @@
1
1
  # @backstage/plugin-app-backend
2
2
 
3
+ ## 0.3.28
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+ - @backstage/backend-common@0.12.0
9
+
10
+ ## 0.3.27
11
+
12
+ ### Patch Changes
13
+
14
+ - Updated dependencies
15
+ - @backstage/backend-common@0.11.0
16
+ - @backstage/config-loader@0.9.6
17
+
18
+ ## 0.3.26
19
+
20
+ ### Patch Changes
21
+
22
+ - Fix for the previous release with missing type declarations.
23
+ - Updated dependencies
24
+ - @backstage/backend-common@0.10.9
25
+ - @backstage/config@0.1.15
26
+ - @backstage/config-loader@0.9.5
27
+ - @backstage/types@0.1.3
28
+
3
29
  ## 0.3.25
4
30
 
5
31
  ### Patch Changes
@@ -0,0 +1,48 @@
1
+ import { PluginDatabaseManager } from '@backstage/backend-common';
2
+ import { Config } from '@backstage/config';
3
+ import express from 'express';
4
+ import { Logger } from 'winston';
5
+
6
+ interface RouterOptions {
7
+ config: Config;
8
+ logger: Logger;
9
+ /**
10
+ * If a database is provided it will be used to cache previously deployed static assets.
11
+ *
12
+ * This is a built-in alternative to using a `staticFallbackHandler`.
13
+ */
14
+ database?: PluginDatabaseManager;
15
+ /**
16
+ * The name of the app package that content should be served from. The same app package should be
17
+ * added as a dependency to the backend package in order for it to be accessible at runtime.
18
+ *
19
+ * In a typical setup with a single app package this would be set to 'app'.
20
+ */
21
+ appPackageName: string;
22
+ /**
23
+ * A request handler to handle requests for static content that are not present in the app bundle.
24
+ *
25
+ * This can be used to avoid issues with clients on older deployment versions trying to access lazy
26
+ * loaded content that is no longer present. Typically the requests would fall back to a long-term
27
+ * object store where all recently deployed versions of the app are present.
28
+ *
29
+ * Another option is to provide a `database` that will take care of storing the static assets instead.
30
+ *
31
+ * If both `database` and `staticFallbackHandler` are provided, the `database` will attempt to serve
32
+ * static assets first, and if they are not found, the `staticFallbackHandler` will be called.
33
+ */
34
+ staticFallbackHandler?: express.Handler;
35
+ /**
36
+ * Disables the configuration injection. This can be useful if you're running in an environment
37
+ * with a read-only filesystem, or for some other reason don't want configuration to be injected.
38
+ *
39
+ * Note that this will cause the configuration used when building the app bundle to be used, unless
40
+ * a separate configuration loading strategy is set up.
41
+ *
42
+ * This also disables configuration injection though `APP_CONFIG_` environment variables.
43
+ */
44
+ disableConfigInjection?: boolean;
45
+ }
46
+ declare function createRouter(options: RouterOptions): Promise<express.Router>;
47
+
48
+ export { RouterOptions, createRouter };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@backstage/plugin-app-backend",
3
3
  "description": "A Backstage backend plugin that serves the Backstage frontend app",
4
- "version": "0.3.25",
4
+ "version": "0.3.28",
5
5
  "main": "dist/index.cjs.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "license": "Apache-2.0",
@@ -33,10 +33,10 @@
33
33
  "clean": "backstage-cli package clean"
34
34
  },
35
35
  "dependencies": {
36
- "@backstage/backend-common": "^0.10.8",
37
- "@backstage/config": "^0.1.14",
38
- "@backstage/config-loader": "^0.9.4",
39
- "@backstage/types": "^0.1.2",
36
+ "@backstage/backend-common": "^0.12.0",
37
+ "@backstage/config": "^0.1.15",
38
+ "@backstage/config-loader": "^0.9.6",
39
+ "@backstage/types": "^0.1.3",
40
40
  "@types/express": "^4.17.6",
41
41
  "express": "^4.17.1",
42
42
  "express-promise-router": "^4.1.0",
@@ -50,9 +50,9 @@
50
50
  "yn": "^4.0.0"
51
51
  },
52
52
  "devDependencies": {
53
- "@backstage/backend-test-utils": "^0.1.18",
54
- "@backstage/cli": "^0.14.0",
55
- "@backstage/types": "^0.1.2",
53
+ "@backstage/backend-test-utils": "^0.1.20",
54
+ "@backstage/cli": "^0.15.0",
55
+ "@backstage/types": "^0.1.3",
56
56
  "@types/supertest": "^2.0.8",
57
57
  "mock-fs": "^5.1.0",
58
58
  "msw": "^0.35.0",
@@ -63,5 +63,5 @@
63
63
  "migrations/**/*.{js,d.ts}",
64
64
  "static"
65
65
  ],
66
- "gitHead": "4805c3d13ce9bfc369e53c271b1b95e722b3b4dc"
66
+ "gitHead": "04bb0dd824b78f6b57dac62c3015e681f094045c"
67
67
  }