Version Packages

This commit is contained in:
github-actions[bot]
2022-01-20 10:33:31 +00:00
parent 4918be78b0
commit 8b18d054f3
302 changed files with 2829 additions and 2214 deletions
+83
View File
@@ -1,5 +1,88 @@
# @backstage/cli
## 0.12.0
### Minor Changes
- 08fa6a604a: Removed the `typescript` dependency from the Backstage CLI in order to decouple the TypeScript version in Backstage projects. To keep using a specific TypeScript version, be sure to add an explicit dependency in your root `package.json`:
```json
"dependencies": {
...
"typescript": "~4.5.4",
}
```
We recommend using a `~` version range since TypeScript releases do not adhere to semver.
It may be the case that you end up with errors if you upgrade the TypeScript version. This is because there was a change to TypeScript not long ago that defaulted the type of errors caught in `catch` blocks to `unknown`. You can work around this by adding `"useUnknownInCatchVariables": false` to the `"compilerOptions"` in your `tsconfig.json`:
```json
"compilerOptions": {
...
"useUnknownInCatchVariables": false
}
```
Another option is to use the utilities from `@backstage/errors` to assert the type of errors caught in `catch` blocks:
```ts
import { assertError, isError } from '@backstage/errors';
try {
...
} catch (error) {
assertError(error);
...
// OR
if (isError(error)) {
...
}
}
```
Yet another issue you might run into when upgrading TypeScript is incompatibilities in the types from `react-use`. The error you would run into looks something like this:
```plain
node_modules/react-use/lib/usePermission.d.ts:1:54 - error TS2304: Cannot find name 'DevicePermissionDescriptor'.
1 declare type PermissionDesc = PermissionDescriptor | DevicePermissionDescriptor | MidiPermissionDescriptor | PushPermissionDescriptor;
```
If you encounter this error, the simplest fix is to replace full imports of `react-use` with more specific ones. For example, the following:
```ts
import { useAsync } from 'react-use';
```
Would be converted into this:
```ts
import useAsync from 'react-use/lib/useAsync';
```
### Patch Changes
- 6e34e2cfbf: Introduce `--deprecated` option to `config:check` to log all deprecated app configuration properties
```sh
$ yarn backstage-cli config:check --lax --deprecated
config:check --lax --deprecated
Loaded config from app-config.yaml
The configuration key 'catalog.processors.githubOrg' of app-config.yaml is deprecated and may be removed soon. Configure a GitHub integration instead.
```
- f2fe4d240b: Switched to only apply `@hot-loader/react-dom` [Webpack aliasing](https://github.com/hot-loader/react-dom/tree/master/source#webpack) when using React 16.
- 2a42d573d2: Introduced a new `--experimental-type-build` option to the various package build commands. This option switches the type definition build to be executed using API Extractor rather than a `rollup` plugin. In order for this experimental switch to work, you must also have `@microsoft/api-extractor` installed within your project, as it is an optional peer dependency.
The biggest difference between the existing mode and the experimental one is that rather than just building a single `dist/index.d.ts` file, API Extractor will output `index.d.ts`, `index.beta.d.ts`, and `index.alpha.d.ts`, all in the `dist` directory. Each of these files will have exports from more unstable release stages stripped, meaning that `index.d.ts` will omit all exports marked with `@alpha` or `@beta`, while `index.beta.d.ts` will omit all exports marked with `@alpha`.
In addition, the `prepack` command now has support for `alphaTypes` and `betaTypes` fields in the `publishConfig` of `package.json`. These optional fields can be pointed to `dist/types.alpha.d.ts` and `dist/types.beta.d.ts` respectively, which will cause `<name>/alpha` and `<name>/beta` entry points to be generated for the package. See the [`@backstage/catalog-model`](https://github.com/backstage/backstage/blob/master/packages/catalog-model/package.json) package for an example of how this can be used in practice.
- Updated dependencies
- @backstage/config@0.1.13
- @backstage/config-loader@0.9.3
## 0.12.0-next.0
### Minor Changes
+10 -10
View File
@@ -1,7 +1,7 @@
{
"name": "@backstage/cli",
"description": "CLI for developing Backstage plugins and apps",
"version": "0.12.0-next.0",
"version": "0.12.0",
"private": false,
"publishConfig": {
"access": "public"
@@ -29,8 +29,8 @@
},
"dependencies": {
"@backstage/cli-common": "^0.1.6",
"@backstage/config": "^0.1.13-next.0",
"@backstage/config-loader": "^0.9.3-next.0",
"@backstage/config": "^0.1.13",
"@backstage/config-loader": "^0.9.3",
"@backstage/errors": "^0.2.0",
"@backstage/types": "^0.1.1",
"@hot-loader/react-dom": "^16.13.0",
@@ -114,13 +114,13 @@
"yn": "^4.0.0"
},
"devDependencies": {
"@backstage/backend-common": "^0.10.4-next.0",
"@backstage/config": "^0.1.13-next.0",
"@backstage/core-components": "^0.8.5-next.0",
"@backstage/core-plugin-api": "^0.6.0-next.0",
"@backstage/core-app-api": "^0.5.0-next.0",
"@backstage/dev-utils": "^0.2.18-next.0",
"@backstage/test-utils": "^0.2.3-next.0",
"@backstage/backend-common": "^0.10.4",
"@backstage/config": "^0.1.13",
"@backstage/core-components": "^0.8.5",
"@backstage/core-plugin-api": "^0.6.0",
"@backstage/core-app-api": "^0.5.0",
"@backstage/dev-utils": "^0.2.18",
"@backstage/test-utils": "^0.2.3",
"@backstage/theme": "^0.2.14",
"@types/diff": "^5.0.0",
"@types/express": "^4.17.6",