Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify usage by updating to new default loop and making Connector optional #100

Merged
merged 2 commits into from
Jul 22, 2021

Conversation

clue
Copy link
Owner

@clue clue commented Jul 22, 2021

This changeset simplifies usage by supporting the new default loop.

// old (still supported)
$proxy = new Clue\React\Socks\Client(
    $url,
    new React\Socket\Connector($loop)
);
$server = new Clue\React\Socks\Server($loop);

// new (using default loop)
$proxy = new Clue\React\Socks\Client('127.0.0.1:1080');
$server = new Clue\React\Socks\Server();

Builds on top of reactphp/event-loop#226, reactphp/event-loop#232, reactphp/socket#260 and reactphp/http#410
Refs clue/reactphp-ssh-proxy#27 and clue/reactphp-http-proxy#41

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant