Skip to content

tipenko/devproxy

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FE Dev proxy

This is an HTTP proxy which will help with FE development of ATG pages. The main and only feature is to proxy HTTP pages and replace some assets accoring to config rules.

Config

Config file ( config.js ) is pretty staightforward. It's a node module which exports a config object

Config prams

port - (optional. default: 8888) - Local proxy server port target - (required) - Target webpage url, for example http://latgipo20int.schneider-electric.com rules - (optional, kind of...) - Array or file-replacement rules object ruleObject.original - (required) = RegExp or string which will be converted to regexp ruleObject.local - (required) = Replacement file path. Can include match groups from regex ( i.e. $1 )

see included config.js as an example.

Getting Started

Clone the repo, adjust config and develop:

$ npm install
$ npm run start

Now http://localhost:8888/shop/us/en/tools/replacement-battery-selector will proxy the http://latgipo20int.schneider-electric.com/shop/us/en/tools/replacement-battery-selector with the file replacement rules applied.

About

devproxy for APCG projects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%