File tree 3 files changed +11
-9
lines changed
3 files changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ const filesConfig : esbuild.BuildOptions = {
51
51
tsconfig : './deno.json' ,
52
52
outdir : './dist' ,
53
53
outbase : './src/client' ,
54
- entryNames : '[dir]/bundle.min ' ,
54
+ entryNames : '[dir]/bundle' ,
55
55
entryPoints : [
56
56
'./src/client/app/**/index.tsx' ,
57
57
'./src/client/app/**/index.scss' ,
Original file line number Diff line number Diff line change 4
4
< meta charset ="UTF-8 " />
5
5
< meta name ="viewport " content ="width=device-width, initial-scale=1.0 " />
6
6
< title > Home</ title >
7
- < link rel ="shortcut icon " href ="/assets/favicon.svg " type ="image/x-icon " />
8
- < link rel ="stylesheet " href ="/bundle.min. css " />
7
+ < link rel ="shortcut icon " href =". /assets/favicon.svg " type ="image/x-icon " />
8
+ < link rel ="stylesheet " href ="/bundle.css " />
9
9
</ head >
10
10
< body >
11
11
< h1 class ="title "> Home</ h1 >
Original file line number Diff line number Diff line change @@ -15,20 +15,22 @@ const routes: Route[] = [
15
15
)
16
16
} ,
17
17
{
18
- pattern : new URLPattern ( { pathname : '/:path*/assets/:dynamicAsset* ' } ) ,
18
+ pattern : new URLPattern ( { pathname : '/:asset ' } ) ,
19
19
handler : ( request , _info , parameters ) => {
20
- const { path , dynamicAsset } = parameters ?. pathname . groups ?? { } ;
20
+ const { asset } = parameters ?. pathname . groups ?? { } ;
21
21
return pageHandler (
22
22
request ,
23
23
appDirectory ,
24
- path ,
25
- '/assets/' + dynamicAsset
24
+ '' ,
25
+ asset
26
26
) ;
27
27
}
28
28
} ,
29
29
{
30
- pattern : new URLPattern ( { pathname : '/:path(.*)' } ) ,
31
- handler : ( request ) => {
30
+ pattern : new URLPattern ( { pathname : '/:page([^\.]*)' } ) ,
31
+ handler : ( request , _info , parameters ) => {
32
+ console . log ( 'page' , parameters ?. pathname . groups . page ) ;
33
+
32
34
return pageHandler ( request , appDirectory , '' )
33
35
}
34
36
}
You can’t perform that action at this time.
0 commit comments