Skip to content

Commit

Permalink
fix: add deno bundler shims to package.json#files (#152)
Browse files Browse the repository at this point in the history
  • Loading branch information
cyco130 authored Sep 8, 2024
1 parent 5ce982a commit 92ceb01
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion packages/bundler/bundler-deno/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"description": "Deno bundler for Hattip",
"files": [
"dist",
"deno-env-shim.js"
"deno-env-shim.js",
"shims"
],
"exports": "./dist/index.js",
"typesVersions": {
Expand Down
4 changes: 2 additions & 2 deletions packages/bundler/bundler-deno/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ Options:
The input should be a Deno module similar to the following:

```js
import { serve, createRequestHandler } from "@hattip/adapter-deno";
import { createRequestHandler } from "@hattip/adapter-deno";
import handler from "./handler.js";

serve(createRequestHandler(handler), { port: 3000 });
Deno.serve(createRequestHandler(handler), { port: 3000 });
```

If you want serve static files too, you can use the `serveDir` function. Assuming your static files are in the `public` directory, you can use the following:
Expand Down

0 comments on commit 92ceb01

Please sign in to comment.