Caching
This commit is contained in:
		
							parent
							
								
									858abd350e
								
							
						
					
					
						commit
						6482fcd6f1
					
				| @ -36,13 +36,14 @@ func (g *guestbook) OnMount(ctx app.Context) { | ||||
| 	g.LoadComments(ctx) | ||||
| } | ||||
| 
 | ||||
| /* | ||||
| func (g *guestbook) OnNav(ctx app.Context) { | ||||
| 	g.LoadComments(ctx) | ||||
| } | ||||
| 
 | ||||
| func (g *guestbook) OnUpdate(ctx app.Context) { | ||||
| 	g.LoadComments(ctx) | ||||
| } | ||||
| }*/ | ||||
| 
 | ||||
| func (g guestbook) Render() app.UI { | ||||
| 	return app.Div().Body( | ||||
|  | ||||
| @ -69,10 +69,5 @@ func (p *Homepage) Render() app.UI { | ||||
| 						}, | ||||
| 					}, | ||||
| 				), | ||||
| 			/* | ||||
| 				newUIBlock(). | ||||
| 					Class("right"). | ||||
| 					Class("contentblock"). | ||||
| 					UI(),*/ | ||||
| 		) | ||||
| } | ||||
|  | ||||
							
								
								
									
										15
									
								
								src/main.go
									
									
									
									
									
								
							
							
						
						
									
										15
									
								
								src/main.go
									
									
									
									
									
								
							| @ -57,7 +57,20 @@ func main() { | ||||
| 			"/web/static/havakana.css", | ||||
| 			"/web/static/form.css", | ||||
| 		}, | ||||
| 		CacheableResources: []string{}, | ||||
| 		CacheableResources: []string{ | ||||
| 			// Images
 | ||||
| 			"/web/static/images/email3.gif", | ||||
| 			"/web/static/images/rin-len1.webp", | ||||
| 			"/web/static/images/background_star.gif", | ||||
| 			"/web/static/images/kanata-1.gif", | ||||
| 			"/web/static/images/rin-1.gif", | ||||
| 			"/web/static/images/rin-2.gif", | ||||
| 			// Pages
 | ||||
| 			"/web/blocks/pages/about.html", | ||||
| 			"/web/blocks/pages/galaxies.html", | ||||
| 			"/web/blocks/pages/intro.html", | ||||
| 			"/web/blocks/snippets/bannerpanel.html", | ||||
| 		}, | ||||
| 	} | ||||
| 
 | ||||
| 	app.GenerateStaticWebsite("./staticsite", handler) | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user