-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
98f117c
commit 54cfe8c
Showing
1 changed file
with
6 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,12 +4,12 @@ Sift is a routing and utility library for | |
[Deno Deploy](https://deno.com/deploy). | ||
|
||
![ci](https://github.com/satyarohith/sift/actions/workflows/ci.yml/badge.svg) | ||
[![deno doc](https://doc.deno.land/badge.svg)](https://doc.deno.land/https/deno.land/x/[email protected].5/mod.ts) | ||
[![deno doc](https://doc.deno.land/badge.svg)](https://doc.deno.land/https/deno.land/x/[email protected].6/mod.ts) | ||
|
||
## Usage | ||
|
||
The documentation below briefly explains the common usage of the functions. You | ||
can visit [deno doc](https://doc.deno.land/https/deno.land/x/[email protected].5/mod.ts) | ||
can visit [deno doc](https://doc.deno.land/https/deno.land/x/[email protected].6/mod.ts) | ||
site to learn more about the API. | ||
|
||
Sift imports some functions from preact which causes type conflicts when running | ||
|
@@ -30,7 +30,7 @@ when the requested path matches the regex, the corresponding handler will be | |
invoked. | ||
|
||
```js | ||
import { serve } from "https://deno.land/x/[email protected].5/mod.ts"; | ||
import { serve } from "https://deno.land/x/[email protected].6/mod.ts"; | ||
|
||
serve({ | ||
"/": () => new Response("hello world"), | ||
|
@@ -57,7 +57,7 @@ If you're serving a directory, it is required that the path string end with | |
requested resource. | ||
|
||
```js | ||
import { serve, serveStatic } from "https://deno.land/x/[email protected].5/mod.ts"; | ||
import { serve, serveStatic } from "https://deno.land/x/[email protected].6/mod.ts"; | ||
|
||
serve({ | ||
// You can serve a single file. | ||
|
@@ -91,7 +91,7 @@ Converts an object literal to a JSON string and creates a `Response` instance | |
with `application/json` as the `content-type`. | ||
```js | ||
import { json, serve } from "https://deno.land/x/[email protected].5/mod.ts"; | ||
import { json, serve } from "https://deno.land/x/[email protected].6/mod.ts"; | ||
|
||
serve({ | ||
"/": () => json({ message: "hello world" }), | ||
|
@@ -109,7 +109,7 @@ When using this function, it is important that your file extension is `.jsx` or | |
imported. | ||
```jsx | ||
import { h, jsx, serve } from "https://deno.land/x/[email protected].5/mod.ts"; | ||
import { h, jsx, serve } from "https://deno.land/x/[email protected].6/mod.ts"; | ||
|
||
const App = () => ( | ||
<div> | ||
|