New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@teambit/component-version

Package Overview
Dependencies
Maintainers
17
Versions
210
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@teambit/component-version - npm Package Compare versions

Comparing version 0.0.396 to 0.0.397

package-tar/teambit-component-version-0.0.397.tgz

3

dist/version.d.ts

@@ -6,2 +6,5 @@ export declare const LATEST_VERSION = "latest";

constructor(versionNum: string | null | undefined, latest: boolean);
/**
* @deprecated this is super old method, which is not relevant anymore.
*/
resolve(availableVersion: string[]): string;

@@ -8,0 +11,0 @@ toString(): string;

@@ -15,2 +15,5 @@ "use strict";

}
/**
* @deprecated this is super old method, which is not relevant anymore.
*/
resolve(availableVersion) {

@@ -17,0 +20,0 @@ const getLatest = () => semver_1.default.maxSatisfying(availableVersion, '*', { includePrerelease: true });

4

package.json
{
"name": "@teambit/component-version",
"version": "0.0.396",
"version": "0.0.397",
"homepage": "https://bit.dev/teambit/component/component-version",

@@ -9,3 +9,3 @@ "main": "dist/index.js",

"name": "component-version",
"version": "0.0.396"
"version": "0.0.397"
},

@@ -12,0 +12,0 @@ "dependencies": {

@@ -15,7 +15,10 @@ import semver from 'semver';

resolve(availableVersion: string[]) {
/**
* @deprecated this is super old method, which is not relevant anymore.
*/
resolve(availableVersion: string[]): string {
const getLatest = () => semver.maxSatisfying(availableVersion, '*', { includePrerelease: true });
if (this.latest) return getLatest();
return this.versionNum;
if (this.latest) return getLatest() as string;
return this.versionNum as string;
}

@@ -22,0 +25,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc