Skip to content

jc3213/easyproxy.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EasyProxy.js

Usage

Lastest Minified Extension
easyproxy.js easyproxy.min.js Easy Proxy

HTML

<script src="https://jc3213.github.io/easyproxy.js/easyproxy.js"></script>

TamperMonkey

// @require https://jc3213.github.io/easyproxy.js/easyproxy.js

Syntax

let router = new EasyProxy();

Properties

routing

  • object
  • read only
let { routing } = router;

pacScript

  • string
  • read only
let { pacScript } = router;

Method

new

router.new(proxy | string"");
router.new(proxy | string"", rules | array[]);

add

router.add(proxy | string"", rule | string"");

delete

router.delete(proxy | string"", rule | string"");

remove

router.remove(proxy | string"");

purge

router.purge();

destroy

router.destroy();

match

let result = router.match(host | string"");

getRules

let rules = router.getRules(proxy | string"");

getScript

let pasScript = router.getScript(proxy | string"");

Static Properties

pacScript

  • string
  • read only
let { pacScript } = EasyProxy;

Static Method

make

let rule = EasyProxy.make(host | string"");

MatchPattern

  • example.com
    • Matches www.example.com, example.com
    • Exclude test-example.com, www.example.com.cn
Match Pattern ↓ www.youtube.com www.facebook.net x.com telegram.org
*
youtube.com
facebook.com
x.com
com
org
youtube
telegram

About

A JavaScript library built on top of MatchPattern.js, aiming to simplify proxy routing and enhance user experience.

Topics

Resources

License

Stars

Watchers

Forks

Contributors