Skip to content

feat: update examples in README.md to use the latest version of http server and oak #18

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

Merged
merged 1 commit into from
Apr 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Table of content:
## Usage

```ts
import { serve } from "https://deno.land/std@0.166.0/http/server.ts";
import { serve } from "https://deno.land/std@0.220.1/http/server.ts";
import { Server } from "https://deno.land/x/socket_io@0.2.0/mod.ts";

const io = new Server();
Expand Down Expand Up @@ -86,9 +86,9 @@ You need to use the [.handle()](https://github.com/oakserver/oak#handle-method)
method:

```ts
import { serve } from "https://deno.land/std@0.166.0/http/server.ts";
import { serve } from "https://deno.land/std@0.220.1/http/server.ts";
import { Server } from "https://deno.land/x/socket_io@0.2.0/mod.ts";
import { Application } from "https://deno.land/x/oak@v11.1.0/mod.ts";
import { Application } from "https://deno.land/x/oak@14.2.0/mod.ts";

const app = new Application();

Expand Down Expand Up @@ -281,12 +281,12 @@ servers.
Documentation: https://socket.io/docs/v4/redis-adapter/

```js
import { serve } from "https://deno.land/std/http/server.ts";
import { serve } from "https://deno.land/std@0.220.1/http/server.ts";
import {
createRedisAdapter,
createRedisClient,
Server,
} from "https://deno.land/x/socket_io/mod.ts";
} from "https://deno.land/x/socket_io@0.2.0/mod.ts";

const [pubClient, subClient] = await Promise.all([
createRedisClient({
Expand Down