Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cloud-url-resolver

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cloud-url-resolver - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

9

dist/index.js

@@ -42,4 +42,11 @@ const inBrowser = typeof window !== "undefined";

}
return `${resolvedProtocol}://localhost:${port}`;
let hostname;
if (!origin) {
hostname = "localhost";
} else {
const url = new URL(origin);
hostname = url.hostname;
}
return `${resolvedProtocol}://${hostname}:${port}`;
}
// # sourceMappingURL=index.js.map

2

package.json
{
"name": "cloud-url-resolver",
"version": "1.2.0",
"version": "1.3.0",
"description": "Allow changing the port and protocol of any common development url",

@@ -5,0 +5,0 @@ "repository": {

@@ -19,5 +19,5 @@ # cloud-url-resolver

```ts
import { resolve } from "cloud-url-resolver";
import { transform } from "cloud-url-resolver";
transform(3000, "http"); // returns "http://localhost:3000" if on localhost; otherwise, returns the transformed for the current platform
```

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