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

localhostify

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

localhostify - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

chrome-ext/icon_128.png

8

bin/createConfig.js

@@ -7,3 +7,3 @@ const fs = require('fs');

const extDir = process.cwd() + '/localhostify-ext';
const extDir = process.cwd() + '/.localhostify-ext';

@@ -18,6 +18,6 @@ if (!fs.existsSync(extDir)) {

fs.writeFileSync(process.cwd() + '/localhostify-ext/config.js', chromeConfig);
fs.copyFileSync(__dirname + '/../chrome-ext/manifest.json', process.cwd() + '/localhostify-ext/manifest.json');
fs.copyFileSync(__dirname + '/../chrome-ext/scripts/http.js', process.cwd() + '/localhostify-ext/scripts/http.js');
fs.copyFileSync(__dirname + '/../chrome-ext/scripts/fetch.js', process.cwd() + '/localhostify-ext/scripts/fetch.js');
fs.copyFileSync(__dirname + '/../chrome-ext/manifest.json', process.cwd() + '/.localhostify-ext/manifest.json');
fs.copyFileSync(__dirname + '/../chrome-ext/scripts/http.js', process.cwd() + '/.localhostify-ext/scripts/http.js');
fs.copyFileSync(__dirname + '/../chrome-ext/scripts/fetch.js', process.cwd() + '/.localhostify-ext/scripts/fetch.js');
console.log("Localhostify: Chrome Ext created in localhostify-ext folder.");
{
"name": "Localhostify",
"version": "0.0.4",
"version": "0.0.5",
"manifest_version": 2,
"description": "Localhostify: External redirects interceptor",
"author": "Salvatore Ravidà",
"homepage_url": "https://github.com/salvoravida/localhostify",
"icons": {
"128": "icon_128.png"
},
"background": {

@@ -7,0 +12,0 @@ "scripts": ["config.js", "scripts/http.js"]

@@ -1,2 +0,4 @@

/* handle custom redirects after fetch */
/**
* https://github.com/salvoravida/localhostify
*/

@@ -3,0 +5,0 @@ function interceptor() {

@@ -1,2 +0,4 @@

/* HTTP headers Location redirect */
/**
* https://github.com/salvoravida/localhostify
*/

@@ -3,0 +5,0 @@ const { externalRedirects } = window.__LOCALHOSTIFY__;

{
"name": "localhostify",
"version": "0.0.4",
"version": "0.0.5",
"description": "Easy HTTP reverse proxy - localhost:3001 -> prod.domain.com",

@@ -5,0 +5,0 @@ "source": "src/index.js",

@@ -34,2 +34,8 @@ <p align="center">

},
externalRedirects: [
{
match: '/api/auth/callback',
replace: ['https://prod.domain.com', 'http://localhost:3001'],
},
],
// allowHeaders: 'content-type', //default cors value

@@ -48,3 +54,3 @@ },

## 💥 Run
```
```shell
your-dev-server start

@@ -54,19 +60,29 @@ npx localhostify prod

```
Browse `http://localhost:3001` and `http://localhost:3002` to enjoy local frotend mixed with real backends enviroments! Hot reload works concurrently!!
Browse `http://localhost:3001` and `http://localhost:3002` to enjoy local frotend mixed with real backends enviroments!<br/>
Hot reload works concurrently!!
<br/><br/>
## 🍭 External Redirects
If your application use external login or SSO you will need to forward browser redirect to localhost.
This happens on the browser side, so we need a web extension.
## 👏 Contributing
```shell
npx localhostify --chrome-ext
```
This command will create a folder ".localhostify-ext" on your project. Load it on Chrome. That's all!.
Note: if you update your .localhostify.js config, please execute again `npx localhostify --chrome-ext` to update also the ext.
It the browser is opened, refresh all the exstensions.
### 👏 Contributing
If you are interested in contributing to `localhostify`, open an issue or a pr!
## 🎉 Thanks
### 🎉 Credits
Thank You, Open Source!
Thank You, Open Source! </br>
Chrome Ext inspired by requestly.io
## 📜 License
### 📜 License
`localhostify` is 100% free and open-source, under [MIT](LICENSE).
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