Full demo
This commit is contained in:
@ -2,14 +2,61 @@ package handlers
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"templ-tests/app/templates"
|
"templ-tests/app/templates"
|
||||||
|
"templ-tests/app/types"
|
||||||
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
var catFacts []types.CatFact = []types.CatFact{
|
||||||
|
{
|
||||||
|
Breed: "Abyssinian",
|
||||||
|
Country: "Ethiopia",
|
||||||
|
Origin: "Natural/Standard",
|
||||||
|
Coat: "Short",
|
||||||
|
Pattern: "Ticked",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
Breed: "Aegean",
|
||||||
|
Country: "Greece",
|
||||||
|
Origin: "Natural/Standard",
|
||||||
|
Coat: "Semi-long",
|
||||||
|
Pattern: "Bi- or tri-colored",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
Breed: "American Curl",
|
||||||
|
Country: "United States",
|
||||||
|
Origin: "Mutation",
|
||||||
|
Coat: "Short/Long",
|
||||||
|
Pattern: "All",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
Breed: "American Bobtail",
|
||||||
|
Country: "United States",
|
||||||
|
Origin: "Mutation",
|
||||||
|
Coat: "Short/Long",
|
||||||
|
Pattern: "All",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
Breed: "American Shorthair",
|
||||||
|
Country: "United States",
|
||||||
|
Origin: "Natural",
|
||||||
|
Coat: "Short",
|
||||||
|
Pattern: "All but colorpoint",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
Breed: "American Wirehair",
|
||||||
|
Country: "United States",
|
||||||
|
Origin: "Mutation",
|
||||||
|
Coat: "Rex",
|
||||||
|
Pattern: "All but colorpoint",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
func About(c *gin.Context) {
|
func About(c *gin.Context) {
|
||||||
pc := templates.PageContext{
|
pc := templates.PageContext{
|
||||||
Title: "Welcome to the demo - About",
|
Title: "Welcome to the demo - About",
|
||||||
ActivePage: "about",
|
ActivePage: "about",
|
||||||
}
|
}
|
||||||
templates.About(pc).Render(c, c.Writer)
|
|
||||||
|
templates.About(pc, catFacts).Render(c, c.Writer)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,14 +2,21 @@ package handlers
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"templ-tests/app/templates"
|
"templ-tests/app/templates"
|
||||||
|
"templ-tests/app/types"
|
||||||
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Home(c *gin.Context) {
|
func Home(c *gin.Context) {
|
||||||
|
user := types.User{
|
||||||
|
FirstName: "Pero",
|
||||||
|
LastName: "Perić",
|
||||||
|
}
|
||||||
|
|
||||||
pc := templates.PageContext{
|
pc := templates.PageContext{
|
||||||
Title: "Welcome to the demo",
|
Title: "Welcome to the demo",
|
||||||
ActivePage: "home",
|
ActivePage: "home",
|
||||||
|
User: &user,
|
||||||
}
|
}
|
||||||
templates.Home(pc, "World").Render(c, c.Writer)
|
templates.Home(pc).Render(c, c.Writer)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,33 @@
|
|||||||
package templates
|
package templates
|
||||||
|
|
||||||
templ About(pc PageContext) {
|
import (
|
||||||
|
"templ-tests/app/types"
|
||||||
|
)
|
||||||
|
|
||||||
|
templ About(pc PageContext, catFacts []types.CatFact) {
|
||||||
@baseLayout(pc) {
|
@baseLayout(pc) {
|
||||||
|
<table class="table">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>Breed</th>
|
||||||
|
<th>Country</th>
|
||||||
|
<th>Origin</th>
|
||||||
|
<th>Coat</th>
|
||||||
|
<th>Pattern</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
for _, fact := range catFacts {
|
||||||
|
<tr>
|
||||||
|
<td>{ fact.Breed }</td>
|
||||||
|
<td>{ fact.Country }</td>
|
||||||
|
<td>{ fact.Origin }</td>
|
||||||
|
<td>{ fact.Coat }</td>
|
||||||
|
<td>{ fact.Pattern }</td>
|
||||||
|
</tr>
|
||||||
|
}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
<p>Bacon ipsum dolor amet cow capicola pancetta picanha biltong brisket filet mignon turducken beef ribs burgdoggen landjaeger meatball venison shank. Capicola ham pork chop, biltong kielbasa pancetta short loin jowl cupim pig jerky drumstick turducken burgdoggen beef. Spare ribs flank ribeye cow doner, shank chuck bacon ham hock porchetta kielbasa tri-tip. Ham t-bone chislic, capicola andouille ham hock frankfurter tri-tip sausage kevin landjaeger shank ribeye. Swine tri-tip spare ribs, rump flank bresaola kevin tail. Meatball tail picanha cow, frankfurter ribeye sirloin pork belly short loin pig. Filet mignon spare ribs pastrami, tri-tip ball tip tongue fatback pork chop.</p>
|
<p>Bacon ipsum dolor amet cow capicola pancetta picanha biltong brisket filet mignon turducken beef ribs burgdoggen landjaeger meatball venison shank. Capicola ham pork chop, biltong kielbasa pancetta short loin jowl cupim pig jerky drumstick turducken burgdoggen beef. Spare ribs flank ribeye cow doner, shank chuck bacon ham hock porchetta kielbasa tri-tip. Ham t-bone chislic, capicola andouille ham hock frankfurter tri-tip sausage kevin landjaeger shank ribeye. Swine tri-tip spare ribs, rump flank bresaola kevin tail. Meatball tail picanha cow, frankfurter ribeye sirloin pork belly short loin pig. Filet mignon spare ribs pastrami, tri-tip ball tip tongue fatback pork chop.</p>
|
||||||
<p>Cupim biltong salami meatball ball tip buffalo, shoulder tenderloin beef ribs porchetta tail boudin chislic. Pastrami short ribs bresaola spare ribs, ham landjaeger brisket flank buffalo sirloin meatloaf tail chislic kielbasa. Leberkas t-bone hamburger pastrami, tri-tip tenderloin spare ribs alcatra filet mignon swine. Pork chop meatball buffalo alcatra cow beef, spare ribs pork loin pork ball tip corned beef sirloin pork belly fatback ham hock. Meatball ham hock filet mignon frankfurter, burgdoggen swine shankle pork belly chuck buffalo andouille corned beef pastrami turkey. Andouille short loin capicola tail pork belly biltong.</p>
|
<p>Cupim biltong salami meatball ball tip buffalo, shoulder tenderloin beef ribs porchetta tail boudin chislic. Pastrami short ribs bresaola spare ribs, ham landjaeger brisket flank buffalo sirloin meatloaf tail chislic kielbasa. Leberkas t-bone hamburger pastrami, tri-tip tenderloin spare ribs alcatra filet mignon swine. Pork chop meatball buffalo alcatra cow beef, spare ribs pork loin pork ball tip corned beef sirloin pork belly fatback ham hock. Meatball ham hock filet mignon frankfurter, burgdoggen swine shankle pork belly chuck buffalo andouille corned beef pastrami turkey. Andouille short loin capicola tail pork belly biltong.</p>
|
||||||
<p>Frankfurter t-bone hamburger meatball tongue capicola. Sausage beef ribs pig, landjaeger salami kielbasa shank cow strip steak doner brisket drumstick sirloin. Ground round ham pork belly pig tri-tip, pastrami ham hock. Bacon shankle brisket rump pork loin drumstick. Chicken shankle picanha corned beef sirloin. Venison kevin jerky ham kielbasa. Prosciutto pork chop brisket pork belly.</p>
|
<p>Frankfurter t-bone hamburger meatball tongue capicola. Sausage beef ribs pig, landjaeger salami kielbasa shank cow strip steak doner brisket drumstick sirloin. Ground round ham pork belly pig tri-tip, pastrami ham hock. Bacon shankle brisket rump pork loin drumstick. Chicken shankle picanha corned beef sirloin. Venison kevin jerky ham kielbasa. Prosciutto pork chop brisket pork belly.</p>
|
||||||
|
|||||||
@ -10,7 +10,11 @@ import "context"
|
|||||||
import "io"
|
import "io"
|
||||||
import "bytes"
|
import "bytes"
|
||||||
|
|
||||||
func About(pc PageContext) templ.Component {
|
import (
|
||||||
|
"templ-tests/app/types"
|
||||||
|
)
|
||||||
|
|
||||||
|
func About(pc PageContext, catFacts []types.CatFact) templ.Component {
|
||||||
return templ.ComponentFunc(func(ctx context.Context, templ_7745c5c3_W io.Writer) (templ_7745c5c3_Err error) {
|
return templ.ComponentFunc(func(ctx context.Context, templ_7745c5c3_W io.Writer) (templ_7745c5c3_Err error) {
|
||||||
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templ_7745c5c3_W.(*bytes.Buffer)
|
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templ_7745c5c3_W.(*bytes.Buffer)
|
||||||
if !templ_7745c5c3_IsBuffer {
|
if !templ_7745c5c3_IsBuffer {
|
||||||
@ -29,57 +33,132 @@ func About(pc PageContext) templ.Component {
|
|||||||
templ_7745c5c3_Buffer = templ.GetBuffer()
|
templ_7745c5c3_Buffer = templ.GetBuffer()
|
||||||
defer templ.ReleaseBuffer(templ_7745c5c3_Buffer)
|
defer templ.ReleaseBuffer(templ_7745c5c3_Buffer)
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<table class=\"table\"><thead><tr><th>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var3 := `Bacon ipsum dolor amet cow capicola pancetta picanha biltong brisket filet mignon turducken beef ribs burgdoggen landjaeger meatball venison shank. Capicola ham pork chop, biltong kielbasa pancetta short loin jowl cupim pig jerky drumstick turducken burgdoggen beef. Spare ribs flank ribeye cow doner, shank chuck bacon ham hock porchetta kielbasa tri-tip. Ham t-bone chislic, capicola andouille ham hock frankfurter tri-tip sausage kevin landjaeger shank ribeye. Swine tri-tip spare ribs, rump flank bresaola kevin tail. Meatball tail picanha cow, frankfurter ribeye sirloin pork belly short loin pig. Filet mignon spare ribs pastrami, tri-tip ball tip tongue fatback pork chop.`
|
templ_7745c5c3_Var3 := `Breed`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var3)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var3)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</th><th>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var4 := `Cupim biltong salami meatball ball tip buffalo, shoulder tenderloin beef ribs porchetta tail boudin chislic. Pastrami short ribs bresaola spare ribs, ham landjaeger brisket flank buffalo sirloin meatloaf tail chislic kielbasa. Leberkas t-bone hamburger pastrami, tri-tip tenderloin spare ribs alcatra filet mignon swine. Pork chop meatball buffalo alcatra cow beef, spare ribs pork loin pork ball tip corned beef sirloin pork belly fatback ham hock. Meatball ham hock filet mignon frankfurter, burgdoggen swine shankle pork belly chuck buffalo andouille corned beef pastrami turkey. Andouille short loin capicola tail pork belly biltong.`
|
templ_7745c5c3_Var4 := `Country`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var4)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var4)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</th><th>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var5 := `Frankfurter t-bone hamburger meatball tongue capicola. Sausage beef ribs pig, landjaeger salami kielbasa shank cow strip steak doner brisket drumstick sirloin. Ground round ham pork belly pig tri-tip, pastrami ham hock. Bacon shankle brisket rump pork loin drumstick. Chicken shankle picanha corned beef sirloin. Venison kevin jerky ham kielbasa. Prosciutto pork chop brisket pork belly.`
|
templ_7745c5c3_Var5 := `Origin`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var5)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var5)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</th><th>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var6 := `Landjaeger tenderloin t-bone turkey buffalo, turducken beef ribs ham hock chuck frankfurter strip steak. Chuck frankfurter jowl jerky tri-tip bacon cow ribeye buffalo capicola bresaola drumstick beef ribs pork belly. Pig brisket tail prosciutto cupim andouille. Venison ground round kielbasa prosciutto jerky spare ribs. Meatball sirloin jerky, turducken tri-tip kevin brisket pork chop sausage rump. Ball tip pork loin frankfurter pig, capicola prosciutto tail bacon short ribs. Chislic porchetta meatloaf, picanha spare ribs kielbasa beef kevin capicola pork loin.`
|
templ_7745c5c3_Var6 := `Coat`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var6)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var6)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</th><th>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var7 := `Tenderloin corned beef prosciutto fatback salami porchetta capicola meatball chuck jowl pork loin shoulder short ribs. Ham hock doner biltong, salami cow jerky bresaola drumstick short loin shankle chuck andouille ground round buffalo. Shankle pork belly landjaeger, corned beef hamburger sausage sirloin swine filet mignon short loin kevin. Jowl picanha pork chop meatball salami corned beef kielbasa. Ribeye leberkas bacon pork loin pig, flank porchetta andouille sausage. T-bone alcatra rump pancetta landjaeger ground round cupim prosciutto shankle ham burgdoggen flank.`
|
templ_7745c5c3_Var7 := `Pattern`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var7)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var7)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</th></tr></thead> <tbody>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var8 := `Jerky turkey pork, burgdoggen shank filet mignon corned beef ham chislic flank prosciutto kielbasa frankfurter. Turkey bresaola salami spare ribs rump, prosciutto short loin strip steak andouille filet mignon tenderloin kielbasa. Flank jowl fatback rump spare ribs. Jowl meatball leberkas rump. Doner buffalo bacon beef pig tail porchetta biltong boudin alcatra pork belly.`
|
for _, fact := range catFacts {
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var8)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<tr><td>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var8 string
|
||||||
|
templ_7745c5c3_Var8, templ_7745c5c3_Err = templ.JoinStringErrs(fact.Breed)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/about.templ`, Line: 21, Col: 22}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var8))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</td><td>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var9 string
|
||||||
|
templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(fact.Country)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/about.templ`, Line: 22, Col: 24}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</td><td>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var10 string
|
||||||
|
templ_7745c5c3_Var10, templ_7745c5c3_Err = templ.JoinStringErrs(fact.Origin)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/about.templ`, Line: 23, Col: 23}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var10))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</td><td>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var11 string
|
||||||
|
templ_7745c5c3_Var11, templ_7745c5c3_Err = templ.JoinStringErrs(fact.Coat)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/about.templ`, Line: 24, Col: 21}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var11))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</td><td>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var12 string
|
||||||
|
templ_7745c5c3_Var12, templ_7745c5c3_Err = templ.JoinStringErrs(fact.Pattern)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/about.templ`, Line: 25, Col: 24}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var12))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</td></tr>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</tbody></table><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var13 := `Bacon ipsum dolor amet cow capicola pancetta picanha biltong brisket filet mignon turducken beef ribs burgdoggen landjaeger meatball venison shank. Capicola ham pork chop, biltong kielbasa pancetta short loin jowl cupim pig jerky drumstick turducken burgdoggen beef. Spare ribs flank ribeye cow doner, shank chuck bacon ham hock porchetta kielbasa tri-tip. Ham t-bone chislic, capicola andouille ham hock frankfurter tri-tip sausage kevin landjaeger shank ribeye. Swine tri-tip spare ribs, rump flank bresaola kevin tail. Meatball tail picanha cow, frankfurter ribeye sirloin pork belly short loin pig. Filet mignon spare ribs pastrami, tri-tip ball tip tongue fatback pork chop.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var13)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
@ -87,8 +166,8 @@ func About(pc PageContext) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var9 := `Porchetta biltong tri-tip kielbasa short ribs ham ground round t-bone venison. Prosciutto hamburger biltong, meatball tongue drumstick ham hock beef ribs. Porchetta jowl boudin, spare ribs tri-tip tenderloin meatloaf shankle landjaeger. Filet mignon meatball ribeye, hamburger kevin turkey cow.`
|
templ_7745c5c3_Var14 := `Cupim biltong salami meatball ball tip buffalo, shoulder tenderloin beef ribs porchetta tail boudin chislic. Pastrami short ribs bresaola spare ribs, ham landjaeger brisket flank buffalo sirloin meatloaf tail chislic kielbasa. Leberkas t-bone hamburger pastrami, tri-tip tenderloin spare ribs alcatra filet mignon swine. Pork chop meatball buffalo alcatra cow beef, spare ribs pork loin pork ball tip corned beef sirloin pork belly fatback ham hock. Meatball ham hock filet mignon frankfurter, burgdoggen swine shankle pork belly chuck buffalo andouille corned beef pastrami turkey. Andouille short loin capicola tail pork belly biltong.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var9)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var14)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
@ -96,8 +175,8 @@ func About(pc PageContext) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var10 := `Kevin andouille sausage pancetta chuck porchetta alcatra meatloaf. Cupim picanha short loin prosciutto leberkas pork, doner ham hock buffalo shankle tongue. Brisket hamburger tail beef chicken shankle capicola meatloaf pork loin porchetta t-bone. Shankle ham hock jowl ham. Sirloin sausage jerky t-bone.`
|
templ_7745c5c3_Var15 := `Frankfurter t-bone hamburger meatball tongue capicola. Sausage beef ribs pig, landjaeger salami kielbasa shank cow strip steak doner brisket drumstick sirloin. Ground round ham pork belly pig tri-tip, pastrami ham hock. Bacon shankle brisket rump pork loin drumstick. Chicken shankle picanha corned beef sirloin. Venison kevin jerky ham kielbasa. Prosciutto pork chop brisket pork belly.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var10)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var15)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
@ -105,8 +184,8 @@ func About(pc PageContext) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var11 := `Jowl bresaola alcatra pastrami pork belly rump short loin shoulder swine jerky flank sirloin andouille. Spare ribs sausage fatback venison flank pancetta. Pork chop ground round sirloin pork belly turkey swine buffalo tri-tip frankfurter landjaeger tongue turducken ball tip. Sirloin jerky meatloaf boudin.`
|
templ_7745c5c3_Var16 := `Landjaeger tenderloin t-bone turkey buffalo, turducken beef ribs ham hock chuck frankfurter strip steak. Chuck frankfurter jowl jerky tri-tip bacon cow ribeye buffalo capicola bresaola drumstick beef ribs pork belly. Pig brisket tail prosciutto cupim andouille. Venison ground round kielbasa prosciutto jerky spare ribs. Meatball sirloin jerky, turducken tri-tip kevin brisket pork chop sausage rump. Ball tip pork loin frankfurter pig, capicola prosciutto tail bacon short ribs. Chislic porchetta meatloaf, picanha spare ribs kielbasa beef kevin capicola pork loin.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var11)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var16)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
@ -114,8 +193,53 @@ func About(pc PageContext) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var12 := `Biltong turducken swine venison bacon, hamburger corned beef pork chop ham hock. Strip steak t-bone ham hock shoulder turducken leberkas chislic sirloin biltong pork belly kielbasa burgdoggen buffalo. T-bone frankfurter jerky, shoulder andouille short ribs rump meatloaf kevin swine tongue. Sirloin corned beef sausage, filet mignon picanha short loin bresaola alcatra boudin strip steak turducken.`
|
templ_7745c5c3_Var17 := `Tenderloin corned beef prosciutto fatback salami porchetta capicola meatball chuck jowl pork loin shoulder short ribs. Ham hock doner biltong, salami cow jerky bresaola drumstick short loin shankle chuck andouille ground round buffalo. Shankle pork belly landjaeger, corned beef hamburger sausage sirloin swine filet mignon short loin kevin. Jowl picanha pork chop meatball salami corned beef kielbasa. Ribeye leberkas bacon pork loin pig, flank porchetta andouille sausage. T-bone alcatra rump pancetta landjaeger ground round cupim prosciutto shankle ham burgdoggen flank.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var12)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var17)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var18 := `Jerky turkey pork, burgdoggen shank filet mignon corned beef ham chislic flank prosciutto kielbasa frankfurter. Turkey bresaola salami spare ribs rump, prosciutto short loin strip steak andouille filet mignon tenderloin kielbasa. Flank jowl fatback rump spare ribs. Jowl meatball leberkas rump. Doner buffalo bacon beef pig tail porchetta biltong boudin alcatra pork belly.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var18)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var19 := `Porchetta biltong tri-tip kielbasa short ribs ham ground round t-bone venison. Prosciutto hamburger biltong, meatball tongue drumstick ham hock beef ribs. Porchetta jowl boudin, spare ribs tri-tip tenderloin meatloaf shankle landjaeger. Filet mignon meatball ribeye, hamburger kevin turkey cow.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var19)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var20 := `Kevin andouille sausage pancetta chuck porchetta alcatra meatloaf. Cupim picanha short loin prosciutto leberkas pork, doner ham hock buffalo shankle tongue. Brisket hamburger tail beef chicken shankle capicola meatloaf pork loin porchetta t-bone. Shankle ham hock jowl ham. Sirloin sausage jerky t-bone.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var20)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var21 := `Jowl bresaola alcatra pastrami pork belly rump short loin shoulder swine jerky flank sirloin andouille. Spare ribs sausage fatback venison flank pancetta. Pork chop ground round sirloin pork belly turkey swine buffalo tri-tip frankfurter landjaeger tongue turducken ball tip. Sirloin jerky meatloaf boudin.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var21)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var22 := `Biltong turducken swine venison bacon, hamburger corned beef pork chop ham hock. Strip steak t-bone ham hock shoulder turducken leberkas chislic sirloin biltong pork belly kielbasa burgdoggen buffalo. T-bone frankfurter jerky, shoulder andouille short ribs rump meatloaf kevin swine tongue. Sirloin corned beef sausage, filet mignon picanha short loin bresaola alcatra boudin strip steak turducken.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var22)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,9 @@
|
|||||||
package templates
|
package templates
|
||||||
|
|
||||||
|
import "templ-tests/app/types"
|
||||||
|
|
||||||
type PageContext struct {
|
type PageContext struct {
|
||||||
Title string
|
Title string
|
||||||
ActivePage string
|
ActivePage string
|
||||||
|
User *types.User
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,10 +1,7 @@
|
|||||||
package templates
|
package templates
|
||||||
|
|
||||||
templ Home(pc PageContext, name string) {
|
templ Home(pc PageContext) {
|
||||||
@baseLayout(pc) {
|
@baseLayout(pc) {
|
||||||
<p class="alert alert-warning">
|
|
||||||
Hello, { name }
|
|
||||||
</p>
|
|
||||||
<p>Bacon ipsum dolor amet venison bacon picanha jerky tenderloin. Hamburger sausage meatball chislic salami. Ball tip tenderloin chuck, venison strip steak kielbasa short loin bresaola short ribs cupim drumstick shoulder pork t-bone. Burgdoggen cupim meatball picanha meatloaf, jowl leberkas kevin. T-bone jowl ham hock salami tenderloin.</p>
|
<p>Bacon ipsum dolor amet venison bacon picanha jerky tenderloin. Hamburger sausage meatball chislic salami. Ball tip tenderloin chuck, venison strip steak kielbasa short loin bresaola short ribs cupim drumstick shoulder pork t-bone. Burgdoggen cupim meatball picanha meatloaf, jowl leberkas kevin. T-bone jowl ham hock salami tenderloin.</p>
|
||||||
<p>Beef ribs frankfurter corned beef ground round pork, sausage drumstick. Corned beef turducken beef ribs, tongue burgdoggen capicola kielbasa short loin pork belly tail frankfurter ribeye strip steak meatloaf. Alcatra frankfurter salami cupim strip steak leberkas jerky ham hock biltong swine ball tip prosciutto t-bone andouille. Pork loin hamburger chuck frankfurter ham shankle jowl sausage chislic chicken tenderloin. Capicola tongue beef ribs flank, doner sirloin tri-tip pastrami. Porchetta andouille pork fatback jerky, pancetta pig filet mignon leberkas kielbasa sirloin.</p>
|
<p>Beef ribs frankfurter corned beef ground round pork, sausage drumstick. Corned beef turducken beef ribs, tongue burgdoggen capicola kielbasa short loin pork belly tail frankfurter ribeye strip steak meatloaf. Alcatra frankfurter salami cupim strip steak leberkas jerky ham hock biltong swine ball tip prosciutto t-bone andouille. Pork loin hamburger chuck frankfurter ham shankle jowl sausage chislic chicken tenderloin. Capicola tongue beef ribs flank, doner sirloin tri-tip pastrami. Porchetta andouille pork fatback jerky, pancetta pig filet mignon leberkas kielbasa sirloin.</p>
|
||||||
<p>Biltong landjaeger drumstick meatball boudin pork chop turducken jerky hamburger filet mignon flank. Venison turducken pork belly, pork chop ground round buffalo strip steak ribeye alcatra pancetta flank salami chislic. Landjaeger flank andouille short ribs. Shoulder beef ribs chuck, corned beef frankfurter turducken prosciutto.</p>
|
<p>Biltong landjaeger drumstick meatball boudin pork chop turducken jerky hamburger filet mignon flank. Venison turducken pork belly, pork chop ground round buffalo strip steak ribeye alcatra pancetta flank salami chislic. Landjaeger flank andouille short ribs. Shoulder beef ribs chuck, corned beef frankfurter turducken prosciutto.</p>
|
||||||
|
|||||||
@ -10,7 +10,7 @@ import "context"
|
|||||||
import "io"
|
import "io"
|
||||||
import "bytes"
|
import "bytes"
|
||||||
|
|
||||||
func Home(pc PageContext, name string) templ.Component {
|
func Home(pc PageContext) templ.Component {
|
||||||
return templ.ComponentFunc(func(ctx context.Context, templ_7745c5c3_W io.Writer) (templ_7745c5c3_Err error) {
|
return templ.ComponentFunc(func(ctx context.Context, templ_7745c5c3_W io.Writer) (templ_7745c5c3_Err error) {
|
||||||
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templ_7745c5c3_W.(*bytes.Buffer)
|
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templ_7745c5c3_W.(*bytes.Buffer)
|
||||||
if !templ_7745c5c3_IsBuffer {
|
if !templ_7745c5c3_IsBuffer {
|
||||||
@ -29,29 +29,29 @@ func Home(pc PageContext, name string) templ.Component {
|
|||||||
templ_7745c5c3_Buffer = templ.GetBuffer()
|
templ_7745c5c3_Buffer = templ.GetBuffer()
|
||||||
defer templ.ReleaseBuffer(templ_7745c5c3_Buffer)
|
defer templ.ReleaseBuffer(templ_7745c5c3_Buffer)
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<p class=\"alert alert-warning\">")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<p>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var3 := `Hello, `
|
templ_7745c5c3_Var3 := `Bacon ipsum dolor amet venison bacon picanha jerky tenderloin. Hamburger sausage meatball chislic salami. Ball tip tenderloin chuck, venison strip steak kielbasa short loin bresaola short ribs cupim drumstick shoulder pork t-bone. Burgdoggen cupim meatball picanha meatloaf, jowl leberkas kevin. T-bone jowl ham hock salami tenderloin.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var3)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var3)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
var templ_7745c5c3_Var4 string
|
|
||||||
templ_7745c5c3_Var4, templ_7745c5c3_Err = templ.JoinStringErrs(name)
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/home.templ`, Line: 5, Col: 16}
|
|
||||||
}
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var4))
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ_7745c5c3_Err
|
|
||||||
}
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var5 := `Bacon ipsum dolor amet venison bacon picanha jerky tenderloin. Hamburger sausage meatball chislic salami. Ball tip tenderloin chuck, venison strip steak kielbasa short loin bresaola short ribs cupim drumstick shoulder pork t-bone. Burgdoggen cupim meatball picanha meatloaf, jowl leberkas kevin. T-bone jowl ham hock salami tenderloin.`
|
templ_7745c5c3_Var4 := `Beef ribs frankfurter corned beef ground round pork, sausage drumstick. Corned beef turducken beef ribs, tongue burgdoggen capicola kielbasa short loin pork belly tail frankfurter ribeye strip steak meatloaf. Alcatra frankfurter salami cupim strip steak leberkas jerky ham hock biltong swine ball tip prosciutto t-bone andouille. Pork loin hamburger chuck frankfurter ham shankle jowl sausage chislic chicken tenderloin. Capicola tongue beef ribs flank, doner sirloin tri-tip pastrami. Porchetta andouille pork fatback jerky, pancetta pig filet mignon leberkas kielbasa sirloin.`
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var4)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var5 := `Biltong landjaeger drumstick meatball boudin pork chop turducken jerky hamburger filet mignon flank. Venison turducken pork belly, pork chop ground round buffalo strip steak ribeye alcatra pancetta flank salami chislic. Landjaeger flank andouille short ribs. Shoulder beef ribs chuck, corned beef frankfurter turducken prosciutto.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var5)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var5)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
@ -60,7 +60,7 @@ func Home(pc PageContext, name string) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var6 := `Beef ribs frankfurter corned beef ground round pork, sausage drumstick. Corned beef turducken beef ribs, tongue burgdoggen capicola kielbasa short loin pork belly tail frankfurter ribeye strip steak meatloaf. Alcatra frankfurter salami cupim strip steak leberkas jerky ham hock biltong swine ball tip prosciutto t-bone andouille. Pork loin hamburger chuck frankfurter ham shankle jowl sausage chislic chicken tenderloin. Capicola tongue beef ribs flank, doner sirloin tri-tip pastrami. Porchetta andouille pork fatback jerky, pancetta pig filet mignon leberkas kielbasa sirloin.`
|
templ_7745c5c3_Var6 := `Beef ribs venison kielbasa, swine andouille ground round cupim shoulder boudin corned beef bacon spare ribs doner strip steak. Pork ribeye flank, chislic fatback sausage alcatra beef ribs beef pork chop buffalo pancetta turducken short ribs. Shoulder ground round chislic filet mignon tri-tip turducken leberkas tenderloin tongue strip steak. Rump bresaola tenderloin, beef ribs buffalo sirloin tail venison porchetta biltong sausage kevin. Chicken kielbasa beef ribs, capicola ham hock shoulder pork belly frankfurter turducken short ribs buffalo boudin.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var6)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var6)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
@ -69,29 +69,11 @@ func Home(pc PageContext, name string) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
templ_7745c5c3_Var7 := `Biltong landjaeger drumstick meatball boudin pork chop turducken jerky hamburger filet mignon flank. Venison turducken pork belly, pork chop ground round buffalo strip steak ribeye alcatra pancetta flank salami chislic. Landjaeger flank andouille short ribs. Shoulder beef ribs chuck, corned beef frankfurter turducken prosciutto.`
|
templ_7745c5c3_Var7 := `Rump meatball shoulder pig cow pork belly jerky pork loin salami corned beef biltong. Pancetta ham hock beef ribs corned beef landjaeger rump shoulder tongue kevin short loin. Pork chop pork loin beef ribs frankfurter bacon cow turkey ham flank pork rump. Sirloin burgdoggen chuck picanha pork ham hock pig tongue pastrami doner meatloaf rump. Prosciutto meatball fatback t-bone bacon biltong pork. Pastrami andouille pig strip steak, ground round corned beef ham hock shankle prosciutto. Pancetta alcatra jerky chislic short ribs.`
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var7)
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var7)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ_7745c5c3_Err
|
|
||||||
}
|
|
||||||
templ_7745c5c3_Var8 := `Beef ribs venison kielbasa, swine andouille ground round cupim shoulder boudin corned beef bacon spare ribs doner strip steak. Pork ribeye flank, chislic fatback sausage alcatra beef ribs beef pork chop buffalo pancetta turducken short ribs. Shoulder ground round chislic filet mignon tri-tip turducken leberkas tenderloin tongue strip steak. Rump bresaola tenderloin, beef ribs buffalo sirloin tail venison porchetta biltong sausage kevin. Chicken kielbasa beef ribs, capicola ham hock shoulder pork belly frankfurter turducken short ribs buffalo boudin.`
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var8)
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ_7745c5c3_Err
|
|
||||||
}
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p><p>")
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ_7745c5c3_Err
|
|
||||||
}
|
|
||||||
templ_7745c5c3_Var9 := `Rump meatball shoulder pig cow pork belly jerky pork loin salami corned beef biltong. Pancetta ham hock beef ribs corned beef landjaeger rump shoulder tongue kevin short loin. Pork chop pork loin beef ribs frankfurter bacon cow turkey ham flank pork rump. Sirloin burgdoggen chuck picanha pork ham hock pig tongue pastrami doner meatloaf rump. Prosciutto meatball fatback t-bone bacon biltong pork. Pastrami andouille pig strip steak, ground round corned beef ham hock shankle prosciutto. Pancetta alcatra jerky chislic short ribs.`
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var9)
|
|
||||||
if templ_7745c5c3_Err != nil {
|
|
||||||
return templ_7745c5c3_Err
|
|
||||||
}
|
|
||||||
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p>")
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p>")
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
|
|||||||
@ -27,6 +27,11 @@ templ baseLayout(pc PageContext) {
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
if pc.User != nil {
|
||||||
|
<p class="alert alert-warning">
|
||||||
|
Hello, { pc.User.FirstName }
|
||||||
|
</p>
|
||||||
|
}
|
||||||
{ children... }
|
{ children... }
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
@ -101,6 +101,30 @@ func baseLayout(pc PageContext) templ.Component {
|
|||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
}
|
}
|
||||||
|
if pc.User != nil {
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("<p class=\"alert alert-warning\">")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
templ_7745c5c3_Var8 := `Hello, `
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ_7745c5c3_Var8)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
var templ_7745c5c3_Var9 string
|
||||||
|
templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(pc.User.FirstName)
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `app/templates/layout.templ`, Line: 31, Col: 32}
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9))
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("</p>")
|
||||||
|
if templ_7745c5c3_Err != nil {
|
||||||
|
return templ_7745c5c3_Err
|
||||||
|
}
|
||||||
|
}
|
||||||
templ_7745c5c3_Err = templ_7745c5c3_Var1.Render(ctx, templ_7745c5c3_Buffer)
|
templ_7745c5c3_Err = templ_7745c5c3_Var1.Render(ctx, templ_7745c5c3_Buffer)
|
||||||
if templ_7745c5c3_Err != nil {
|
if templ_7745c5c3_Err != nil {
|
||||||
return templ_7745c5c3_Err
|
return templ_7745c5c3_Err
|
||||||
|
|||||||
9
app/types/catfacts.go
Normal file
9
app/types/catfacts.go
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
package types
|
||||||
|
|
||||||
|
type CatFact struct {
|
||||||
|
Breed string
|
||||||
|
Country string
|
||||||
|
Origin string
|
||||||
|
Coat string
|
||||||
|
Pattern string
|
||||||
|
}
|
||||||
6
app/types/user.go
Normal file
6
app/types/user.go
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
package types
|
||||||
|
|
||||||
|
type User struct {
|
||||||
|
FirstName string
|
||||||
|
LastName string
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user