chore: restructure repository into packages/ folder (#3197)
We're having a growing number of packages in this repository. This PR moves them into a `packages/` directory like it's commonly done in other projects.
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"workspace": [],
|
||||
"lock": false,
|
||||
"links": ["../../.."],
|
||||
"compilerOptions": {
|
||||
"jsx": "precompile",
|
||||
"jsxImportSource": "preact",
|
||||
"jsxPrecompileSkipElements": ["a", "img", "source", "body", "html", "head"]
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
import { App } from "../../../src/app.ts";
|
||||
|
||||
const app = new App().get(
|
||||
"/",
|
||||
(ctx) =>
|
||||
ctx.render(
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>foo</title>
|
||||
</head>
|
||||
<body>
|
||||
<div f-client-nav>
|
||||
<span f-client-nav={false}>
|
||||
<p>false</p>
|
||||
</span>
|
||||
<a href="/">Home</a>
|
||||
<img src="/foo.jpg" alt="" />
|
||||
<picture>
|
||||
<source src="/bar.jpg" />
|
||||
</picture>
|
||||
</div>
|
||||
</body>
|
||||
</html>,
|
||||
),
|
||||
);
|
||||
|
||||
const handler = app.handler();
|
||||
const res = await handler(new Request("http://localhost/"));
|
||||
// deno-lint-ignore no-console
|
||||
console.log(await res.text());
|
||||
Reference in New Issue
Block a user