Skip to content

Commit

Permalink
Merge pull request #216 from sejori/readme-update
Browse files Browse the repository at this point in the history
Readme update
  • Loading branch information
sejori authored Aug 22, 2024
2 parents c3304dd + acf476b commit 181e82b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</h1>

<p align="center">
<strong>Fast</strong> - Regex route matcher. Works out-of-the-box with Deno, Bun & Cloudflare Workers 🏎️💨
<strong>Fast</strong> - Regex route matching and caching with Node, Deno, Bun & Cloudflare Worker support 🏎️💨
</p>
<p align="center">
<strong>Featherweight</strong> - Functional API built with Web Standards & zero dependencies 🪶<br>
Expand Down Expand Up @@ -51,14 +51,19 @@
</span>
</p>

```bash
npm i @sejori/peko
```

<h2 id="overview">Overview</h2>

Routes and middleware are added to a `Router` instance with `.use`, `.addRoute` or `.get/post/put/delete`.

The router is then used with your web server of choice, e.g. `Deno.serve` or `Bun.serve`.


```js
import * as Peko from "https://deno.land/x/peko/mod.ts";
import * as Peko from "@sejori/peko"; // or https://deno.land/x/peko/mod.ts in Deno

const router = new Peko.Router();

Expand Down Expand Up @@ -197,7 +202,7 @@ router.addRoute(
The cacher stores response items in memory by default, but it can be extended to use any key value storage by supplying the `store` options parameter (e.g. Cloudflare Workers KV).

```js
import { Router, CacheItem, cacher } from "https://deno.land/x/peko/mod.ts";
import { Router, CacheItem, cacher } from "@sejori/peko";

const router = new Router();

Expand All @@ -220,10 +225,10 @@ router.addRoute("/get-time", {

PR to add your project 🙌

### [shineponics.deno.dev](https://shineponics.deno.dev)
### [shineon.systems](https://shineon.systems)

- **Stack:** React, Google Cloud Platform
- **Features:** Google Sheet analytics, GCP email list, Markdown rendering
- **Stack:** React, Cloudflare Workers, KV and R2
- **Features:** KV cache, R2 email list, Markdown rendering
- [source](https://github.com/shine-systems/shineponics/blob/main/server.ts)

### [thesebsite.deno.dev](https://thesebsite.deno.dev)
Expand Down
2 changes: 1 addition & 1 deletion example/reactSSR/src/document.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export default (input: {
document.getElementById('root'),
App(${JSON.stringify(input.serverState)})
);
</script
</script>
</body>
</html>
`;

0 comments on commit 181e82b

Please sign in to comment.