@code-pushup/js-packages-plugin 0.90.0 → 0.90.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@code-pushup/js-packages-plugin",
3
- "version": "0.90.0",
3
+ "version": "0.90.1",
4
4
  "description": "Code PushUp plugin for JavaScript packages 🛡️",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/code-pushup/cli/tree/main/packages/plugin-js-packages#readme",
@@ -37,8 +37,8 @@
37
37
  },
38
38
  "type": "module",
39
39
  "dependencies": {
40
- "@code-pushup/models": "0.90.0",
41
- "@code-pushup/utils": "0.90.0",
40
+ "@code-pushup/models": "0.90.1",
41
+ "@code-pushup/utils": "0.90.1",
42
42
  "build-md": "^0.4.1",
43
43
  "semver": "^7.6.0",
44
44
  "yargs": "^17.7.2",
@@ -2,9 +2,11 @@ import { objectToEntries } from '@code-pushup/utils';
2
2
  import { filterOutWarnings } from './utils.js';
3
3
  export function pnpmToOutdatedResult(output) {
4
4
  const pnpmOutdated = JSON.parse(filterOutWarnings(output));
5
- return objectToEntries(pnpmOutdated).map(([name, { current, latest, dependencyType: type }]) => ({
5
+ // "current" may be missing if package is not installed
6
+ // Fallback to "wanted" - same approach as npm
7
+ return objectToEntries(pnpmOutdated).map(([name, { current, latest, wanted, dependencyType: type }]) => ({
6
8
  name,
7
- current,
9
+ current: current || wanted,
8
10
  latest,
9
11
  type,
10
12
  }));
@@ -1 +1 @@
1
- {"version":3,"file":"outdated-result.js","sourceRoot":"","sources":["../../../../../src/lib/package-managers/pnpm/outdated-result.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAGrD,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAE/C,MAAM,UAAU,oBAAoB,CAAC,MAAc;IACjD,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAC7B,iBAAiB,CAAC,MAAM,CAAC,CACA,CAAC;IAE5B,OAAO,eAAe,CAAC,YAAY,CAAC,CAAC,GAAG,CACtC,CAAC,CAAC,IAAI,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;QACtD,IAAI;QACJ,OAAO;QACP,MAAM;QACN,IAAI;KACL,CAAC,CACH,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"outdated-result.js","sourceRoot":"","sources":["../../../../../src/lib/package-managers/pnpm/outdated-result.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAGrD,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAE/C,MAAM,UAAU,oBAAoB,CAAC,MAAc;IACjD,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAC7B,iBAAiB,CAAC,MAAM,CAAC,CACA,CAAC;IAE5B,uDAAuD;IACvD,8CAA8C;IAC9C,OAAO,eAAe,CAAC,YAAY,CAAC,CAAC,GAAG,CACtC,CAAC,CAAC,IAAI,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9D,IAAI;QACJ,OAAO,EAAE,OAAO,IAAI,MAAM;QAC1B,MAAM;QACN,IAAI;KACL,CAAC,CACH,CAAC;AACJ,CAAC"}
@@ -19,8 +19,9 @@ export type PnpmAuditResultJson = {
19
19
  };
20
20
  };
21
21
  export type PnpmVersionOverview = {
22
- current: string;
22
+ current?: string;
23
23
  latest: string;
24
+ wanted: string;
24
25
  dependencyType: DependencyGroupLong;
25
26
  };
26
27
  export type PnpmOutdatedResultJson = Record<string, PnpmVersionOverview>;