SYMBOL INDEX (3138 symbols across 400 files)
FILE: benchmarks/templ/data.go
type Person (line 3) | type Person struct
FILE: benchmarks/templ/render_test.go
function BenchmarkTemplRender (line 15) | func BenchmarkTemplRender(b *testing.B) {
function BenchmarkTemplParser (line 35) | func BenchmarkTemplParser(b *testing.B) {
function BenchmarkGoTemplateRender (line 59) | func BenchmarkGoTemplateRender(b *testing.B) {
constant html (line 75) | html = `
Luiz Bonfa
[...]
function run (line 43) | func run(stdin io.Reader, stdout, stderr io.Writer, args []string) (code...
constant infoUsageText (line 68) | infoUsageText = `usage: templ info [...]
function infoCmd (line 83) | func infoCmd(stdout, stderr io.Writer, args []string) (code int) {
function generateCmd (line 121) | func generateCmd(stdout, stderr io.Writer, args []string) (code int) {
type ErrorCode (line 144) | type ErrorCode interface
constant fmtUsageText (line 149) | fmtUsageText = `usage: templ fmt [ ...]
function fmtCmd (line 185) | func fmtCmd(stdin io.Reader, stdout, stderr io.Writer, args []string) (c...
constant lspUsageText (line 223) | lspUsageText = `usage: templ lsp [ ...]
function lspCmd (line 246) | func lspCmd(stdin io.Reader, stdout, stderr io.Writer, args []string) (c...
FILE: cmd/templ/main_test.go
function TestMain (line 12) | func TestMain(t *testing.T) {
FILE: cmd/templ/processor/processor.go
type Result (line 13) | type Result struct
function Process (line 20) | func Process(dir string, f func(fileName string) (error, bool), workerCo...
function FindTemplates (line 31) | func FindTemplates(srcPath string, output chan<- string) (err error) {
function ProcessChannel (line 46) | func ProcessChannel(templates <-chan string, dir string, f func(fileName...
FILE: cmd/templ/processor/processor_test.go
function TestFindTemplates (line 8) | func TestFindTemplates(t *testing.T) {
FILE: cmd/templ/sloghandler/handler.go
function NewLogger (line 13) | func NewLogger(logLevel string, verbose bool, stderr io.Writer) *slog.Lo...
type Handler (line 34) | type Handler struct
method Enabled (line 84) | func (h *Handler) Enabled(ctx context.Context, level slog.Level) bool {
method WithAttrs (line 88) | func (h *Handler) WithAttrs(attrs []slog.Attr) slog.Handler {
method WithGroup (line 92) | func (h *Handler) WithGroup(name string) slog.Handler {
method Handle (line 98) | func (h *Handler) Handle(ctx context.Context, r slog.Record) (err erro...
function NewHandler (line 53) | func NewHandler(w io.Writer, opts *slog.HandlerOptions) *Handler {
FILE: cmd/templ/testproject/testdata/css-classes/classes.go
constant Header (line 3) | Header = "header"
FILE: cmd/templ/testproject/testdata/main.go
function main (line 14) | func main() {
FILE: cmd/templ/testproject/testdata/remotechild_templ.go
function Remote (line 10) | func Remote() templ.Component {
FILE: cmd/templ/testproject/testdata/remoteparent_templ.go
function RemoteInclusionTest (line 10) | func RemoteInclusionTest() templ.Component {
function Remote2 (line 39) | func Remote2() templ.Component {
FILE: cmd/templ/testproject/testdata/templates_templ.go
function Page (line 12) | func Page(count int) templ.Component {
type Struct (line 56) | type Struct struct
FILE: cmd/templ/testproject/testproject.go
function Create (line 15) | func Create(moduleRoot string) (dir string, err error) {
function MustReplaceLine (line 66) | func MustReplaceLine(file string, line int, replacement string) string {
FILE: cmd/templ/visualize/sourcemapvisualisation_templ.go
function row (line 10) | func row() templ.CSSClass {
function column (line 20) | func column() templ.CSSClass {
function code (line 32) | func code() templ.CSSClass {
function combine (line 42) | func combine(templFileName string, left, right templ.Component) templ.Co...
function highlight (line 179) | func highlight(sourceId, targetId string) templ.ComponentScript {
function removeHighlight (line 196) | func removeHighlight(sourceId, targetId string) templ.ComponentScript {
function mappedCharacter (line 213) | func mappedCharacter(s string, sourceID, targetID string) templ.Component {
FILE: cmd/templ/visualize/types.go
function HTML (line 15) | func HTML(templFileName string, templContents, goContents string, source...
type templLines (line 21) | type templLines struct
method Render (line 26) | func (tl templLines) Render(ctx context.Context, w io.Writer) (err err...
type goLines (line 55) | type goLines struct
method Render (line 60) | func (gl goLines) Render(ctx context.Context, w io.Writer) (err error) {
FILE: docs/docs/main.go
type Section (line 12) | type Section struct
type ItemToCreate (line 17) | type ItemToCreate struct
function main (line 24) | func main() {
function categoryJSON (line 92) | func categoryJSON(position int, label string) string {
type Category (line 106) | type Category struct
FILE: docs/src/theme/prism-include-languages.js
function prismIncludeLanguages (line 2) | function prismIncludeLanguages(PrismObject) {
FILE: examples/blog/main.go
function main (line 11) | func main() {
function NewPostsHandler (line 25) | func NewPostsHandler() PostsHandler {
type PostsHandler (line 36) | type PostsHandler struct
method ServeHTTP (line 41) | func (ph PostsHandler) ServeHTTP(w http.ResponseWriter, r *http.Reques...
type Post (line 51) | type Post struct
FILE: examples/blog/posts_templ.go
function headerTemplate (line 15) | func headerTemplate(name string) templ.Component {
function footerTemplate (line 57) | func footerTemplate() templ.Component {
function navTemplate (line 99) | func navTemplate() templ.Component {
function layout (line 128) | func layout(name string) templ.Component {
function postsTemplate (line 198) | func postsTemplate(posts []Post) templ.Component {
function home (line 263) | func home() templ.Component {
function posts (line 310) | func posts(posts []Post) templ.Component {
FILE: examples/blog/posts_test.go
function TestHeader (line 17) | func TestHeader(t *testing.T) {
function TestFooter (line 39) | func TestFooter(t *testing.T) {
function TestNav (line 61) | func TestNav(t *testing.T) {
function TestHome (line 77) | func TestHome(t *testing.T) {
function TestPosts (line 106) | func TestPosts(t *testing.T) {
function TestPostsHandler (line 155) | func TestPostsHandler(t *testing.T) {
FILE: examples/content-security-policy/main.go
function main (line 15) | func main() {
function NewCSPMiddleware (line 31) | func NewCSPMiddleware(log *slog.Logger, next http.Handler) *CSPMiddleware {
type CSPMiddleware (line 39) | type CSPMiddleware struct
method ServeHTTP (line 45) | func (m *CSPMiddleware) ServeHTTP(w http.ResponseWriter, r *http.Reque...
method generateNonce (line 57) | func (m *CSPMiddleware) generateNonce() (string, error) {
FILE: examples/content-security-policy/templates_templ.go
function sayHello (line 10) | func sayHello() templ.ComponentScript {
function template (line 20) | func template() templ.Component {
FILE: examples/counter-basic/components_templ.go
function counts (line 12) | func counts(global, user int) templ.Component {
function form (line 67) | func form() templ.Component {
function page (line 96) | func page(global, user int) templ.Component {
FILE: examples/counter-basic/main.go
type GlobalState (line 12) | type GlobalState struct
function getHandler (line 19) | func getHandler(w http.ResponseWriter, r *http.Request) {
function postHandler (line 25) | func postHandler(w http.ResponseWriter, r *http.Request) {
function main (line 42) | func main() {
FILE: examples/counter/cdk/stack.go
type CounterStackProps (line 19) | type CounterStackProps struct
function NewCounterStack (line 23) | func NewCounterStack(scope constructs.Construct, id string, props *Count...
function main (line 131) | func main() {
FILE: examples/counter/components/components_templ.go
function border (line 12) | func border() templ.CSSClass {
function counts (line 26) | func counts(global, session int) templ.Component {
function Page (line 125) | func Page(global, session int) templ.Component {
FILE: examples/counter/db/db.go
type OptionsFunc (line 14) | type OptionsFunc
function WithClient (line 16) | func WithClient(client *dynamodb.Client) func(*CountStore) {
function NewCountStore (line 22) | func NewCountStore(tableName, region string, options ...OptionsFunc) (s ...
type CountStore (line 39) | type CountStore struct
method BatchGet (line 58) | func (s CountStore) BatchGet(ctx context.Context, ids ...string) (coun...
method Get (line 128) | func (s CountStore) Get(ctx context.Context, id string) (count int, er...
method Increment (line 155) | func (s CountStore) Increment(ctx context.Context, id string) (count i...
function stripEmpty (line 44) | func stripEmpty(strings []string) (op []string) {
type countRecord (line 53) | type countRecord struct
FILE: examples/counter/handlers/default.go
type CountService (line 13) | type CountService interface
function New (line 18) | func New(log *slog.Logger, cs CountService) *DefaultHandler {
type DefaultHandler (line 25) | type DefaultHandler struct
method ServeHTTP (line 30) | func (h *DefaultHandler) ServeHTTP(w http.ResponseWriter, r *http.Requ...
method Get (line 38) | func (h *DefaultHandler) Get(w http.ResponseWriter, r *http.Request) {
method Post (line 50) | func (h *DefaultHandler) Post(w http.ResponseWriter, r *http.Request) {
method View (line 79) | func (h *DefaultHandler) View(w http.ResponseWriter, r *http.Request, ...
type ViewProps (line 75) | type ViewProps struct
FILE: examples/counter/lambda/main.go
function main (line 14) | func main() {
FILE: examples/counter/main.go
function main (line 16) | func main() {
FILE: examples/counter/services/count.go
type Counts (line 13) | type Counts struct
type IncrementType (line 18) | type IncrementType
constant IncrementTypeUnknown (line 21) | IncrementTypeUnknown IncrementType = iota
constant IncrementTypeGlobal (line 22) | IncrementTypeGlobal
constant IncrementTypeSession (line 23) | IncrementTypeSession
function NewCount (line 28) | func NewCount(log *slog.Logger, cs *db.CountStore) Count {
type Count (line 35) | type Count struct
method Increment (line 40) | func (cs Count) Increment(ctx context.Context, it IncrementType, sessi...
method Get (line 71) | func (cs Count) Get(ctx context.Context, sessionID string) (counts Cou...
FILE: examples/counter/session/session.go
type MiddlewareOpts (line 9) | type MiddlewareOpts
function NewMiddleware (line 11) | func NewMiddleware(next http.Handler, opts ...MiddlewareOpts) http.Handl...
function WithSecure (line 23) | func WithSecure(secure bool) MiddlewareOpts {
function WithHTTPOnly (line 29) | func WithHTTPOnly(httpOnly bool) MiddlewareOpts {
type Middleware (line 35) | type Middleware struct
method ServeHTTP (line 49) | func (mw Middleware) ServeHTTP(w http.ResponseWriter, r *http.Request) {
function ID (line 41) | func ID(r *http.Request) (id string) {
FILE: examples/external-libraries/components_templ.go
function graph (line 10) | func graph(data []TimeValue) templ.ComponentScript {
function page (line 22) | func page(data []TimeValue) templ.Component {
FILE: examples/external-libraries/main.go
type TimeValue (line 9) | type TimeValue struct
function main (line 14) | func main() {
FILE: examples/hello-world-ssr/hello_templ.go
function hello (line 10) | func hello(name string) templ.Component {
FILE: examples/hello-world-ssr/main.go
function main (line 11) | func main() {
FILE: examples/hello-world-static/hello_templ.go
function hello (line 10) | func hello(name string) templ.Component {
FILE: examples/hello-world-static/main.go
function main (line 9) | func main() {
FILE: examples/htmx-fragments/main_templ.go
type PageState (line 16) | type PageState struct
function Page (line 21) | func Page(state PageState) templ.Component {
function handleRequest (line 104) | func handleRequest(w http.ResponseWriter, r *http.Request) {
function main (line 120) | func main() {
FILE: examples/integration-chi/home_templ.go
function Home (line 10) | func Home() templ.Component {
FILE: examples/integration-chi/main.go
function main (line 10) | func main() {
FILE: examples/integration-echo/home_templ.go
function Home (line 10) | func Home() templ.Component {
FILE: examples/integration-echo/main.go
function main (line 10) | func main() {
function Render (line 17) | func Render(ctx echo.Context, statusCode int, t templ.Component) error {
function HomeHandler (line 28) | func HomeHandler(c echo.Context) error {
FILE: examples/integration-gin/gintemplrenderer/renderer.go
type HTMLTemplRenderer (line 13) | type HTMLTemplRenderer struct
method Instance (line 17) | func (r *HTMLTemplRenderer) Instance(s string, d any) render.Render {
function New (line 31) | func New(ctx context.Context, status int, component templ.Component) *Re...
type Renderer (line 39) | type Renderer struct
method Render (line 45) | func (t Renderer) Render(w http.ResponseWriter) error {
method WriteContentType (line 56) | func (t Renderer) WriteContentType(w http.ResponseWriter) {
FILE: examples/integration-gin/home_templ.go
function Home (line 10) | func Home() templ.Component {
FILE: examples/integration-gin/main.go
function main (line 10) | func main() {
FILE: examples/integration-go-echarts/components_templ.go
function Home (line 12) | func Home(chart *charts.Bar) templ.Component {
FILE: examples/integration-go-echarts/main.go
function generateBarItems (line 14) | func generateBarItems() []opts.BarData {
function createBarChart (line 22) | func createBarChart() *charts.Bar {
type Renderable (line 36) | type Renderable interface
function ConvertChartToTemplComponent (line 41) | func ConvertChartToTemplComponent(chart Renderable) templ.Component {
function main (line 47) | func main() {
FILE: examples/integration-gofiber/home_templ.go
function NameFromContext (line 12) | func NameFromContext(ctx context.Context) string {
function Home (line 19) | func Home(name string) templ.Component {
function NotFound (line 74) | func NotFound() templ.Component {
FILE: examples/integration-gofiber/main.go
function main (line 9) | func main() {
function NotFoundMiddleware (line 25) | func NotFoundMiddleware(c fiber.Ctx) error {
function Render (line 30) | func Render(c fiber.Ctx, component templ.Component) error {
FILE: examples/integration-react/components_templ.go
function Hello (line 10) | func Hello(name string) templ.Component {
function page (line 52) | func page() templ.Component {
FILE: examples/integration-react/main.go
function main (line 11) | func main() {
FILE: examples/integration-react/react/index.ts
function renderHello (line 21) | function renderHello(e: HTMLElement) {
FILE: examples/integration-react/static/index.js
function rf (line 1) | function rf(e){return e===null||typeof e!="object"?null:(e=Zu&&e[Zu]||e[...
function On (line 1) | function On(e,n,t){this.props=e,this.context=n,this.refs=ni,this.updater...
function ti (line 1) | function ti(){}
function zl (line 1) | function zl(e,n,t){this.props=e,this.context=n,this.refs=ni,this.updater...
function oi (line 1) | function oi(e,n,t){var r,l={},o=null,u=null;if(n!=null)for(r in n.ref!==...
function lf (line 1) | function lf(e,n){return{$$typeof:st,type:e.type,key:n,ref:e.ref,props:e....
function Rl (line 1) | function Rl(e){return typeof e=="object"&&e!==null&&e.$$typeof===st}
function of (line 1) | function of(e){var n={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,fun...
function Pl (line 1) | function Pl(e,n){return typeof e=="object"&&e!==null&&e.key!=null?of(""+...
function rr (line 1) | function rr(e,n,t,r,l){var o=typeof e;(o==="undefined"||o==="boolean")&&...
function tr (line 1) | function tr(e,n,t){if(e==null)return e;var r=[],l=0;return rr(e,r,"","",...
function uf (line 1) | function uf(e){if(e._status===-1){var n=e._result;n=n(),n.then(function(...
function Fl (line 1) | function Fl(e,n){var t=e.length;e.push(n);e:for(;0>>1,l=e...
function _e (line 1) | function _e(e){return e.length===0?null:e[0]}
function ir (line 1) | function ir(e){if(e.length===0)return null;var n=e[0],t=e.pop();if(t!==n...
function or (line 1) | function or(e,n){var t=e.sortIndex-n.sortIndex;return t!==0?t:e.id-n.id}
function jl (line 1) | function jl(e){for(var n=_e(Ge);n!==null;){if(n.callback===null)ir(Ge);e...
function Ul (line 1) | function Ul(e){if(ct=!1,jl(e),!yn)if(_e(Re)!==null)yn=!0,Al(Vl);else{var...
function Vl (line 1) | function Vl(e,n){yn=!1,ct&&(ct=!1,pi(ft),ft=-1),sr=!0;var t=Z;try{for(jl...
function hi (line 1) | function hi(){return!(L.unstable_now()-vi"u"||df(e,n,t,r))return!0;if(...
function le (line 1) | function le(e,n,t,r,l,o,u){this.acceptsBooleans=n===2||n===3||n===4,this...
function lu (line 1) | function lu(e){return e[1].toUpperCase()}
function ou (line 1) | function ou(e,n,t,r){var l=G.hasOwnProperty(n)?G[n]:null;(l!==null?l.typ...
function dt (line 1) | function dt(e){return e===null||typeof e!="object"?null:(e=Ei&&e[Ei]||e[...
function St (line 1) | function St(e){if(Bl===void 0)try{throw Error()}catch(t){var n=t.stack.t...
function $l (line 2) | function $l(e,n){if(!e||Wl)return"";Wl=!0;var t=Error.prepareStackTrace;...
function mf (line 5) | function mf(e){switch(e.tag){case 5:return St(e.type);case 16:return St(...
function vo (line 5) | function vo(e){if(e==null)return null;if(typeof e=="function")return e.d...
function vf (line 5) | function vf(e){var n=e.type;switch(e.tag){case 24:return"Cache";case 9:r...
function dn (line 5) | function dn(e){switch(typeof e){case"boolean":case"number":case"string":...
function Rs (line 5) | function Rs(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="inp...
function hf (line 5) | function hf(e){var n=Rs(e)?"checked":"value",t=Object.getOwnPropertyDesc...
function fr (line 5) | function fr(e){e._valueTracker||(e._valueTracker=hf(e))}
function Os (line 5) | function Os(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var t...
function Vr (line 5) | function Vr(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u...
function ho (line 5) | function ho(e,n){var t=n.checked;return j({},n,{defaultChecked:void 0,de...
function _i (line 5) | function _i(e,n){var t=n.defaultValue==null?"":n.defaultValue,r=n.checke...
function Ds (line 5) | function Ds(e,n){n=n.checked,n!=null&&ou(e,"checked",n,!1)}
function yo (line 5) | function yo(e,n){Ds(e,n);var t=dn(n.value),r=n.type;if(t!=null)r==="numb...
function Ci (line 5) | function Ci(e,n,t){if(n.hasOwnProperty("value")||n.hasOwnProperty("defau...
function go (line 5) | function go(e,n,t){(n!=="number"||Vr(e.ownerDocument)!==e)&&(t==null?e.d...
function Yn (line 5) | function Yn(e,n,t,r){if(e=e.options,n){n={};for(var l=0;l>>=0,e===0?32:31-(Tf(e)/Lf|0)|0}
function Et (line 5) | function Et(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:retur...
function Wr (line 5) | function Wr(e,n){var t=e.pendingLanes;if(t===0)return 0;var r=0,l=e.susp...
function Of (line 5) | function Of(e,n){switch(e){case 1:case 2:case 4:return n+250;case 8:case...
function Df (line 5) | function Df(e,n){for(var t=e.suspendedLanes,r=e.pingedLanes,l=e.expirati...
function Po (line 5) | function Po(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?...
function Zs (line 5) | function Zs(){var e=pr;return pr<<=1,!(pr&4194240)&&(pr=64),e}
function Kl (line 5) | function Kl(e){for(var n=[],t=0;31>t;t++)n.push(e);return n}
function Zt (line 5) | function Zt(e,n,t){e.pendingLanes|=n,n!==536870912&&(e.suspendedLanes=0,...
function Mf (line 5) | function Mf(e,n){var t=e.pendingLanes&~n;e.pendingLanes=n,e.suspendedLan...
function fu (line 5) | function fu(e,n){var t=e.entangledLanes|=n;for(e=e.entanglements;t;){var...
function Js (line 5) | function Js(e){return e&=-e,1Hn||(e.current=jo[Hn],jo[Hn]=null,Hn--)}
function R (line 6) | function R(e,n){Hn++,jo[Hn]=e.current,e.current=n}
function et (line 6) | function et(e,n){var t=e.type.contextTypes;if(!t)return pn;var r=e.state...
function se (line 6) | function se(e){return e=e.childContextTypes,e!=null}
function Xr (line 6) | function Xr(){D(ie),D(ee)}
function Ji (line 6) | function Ji(e,n,t){if(ee.current!==pn)throw Error(h(168));R(ee,n),R(ie,t)}
function ka (line 6) | function ka(e,n,t){var r=e.stateNode;if(n=n.childContextTypes,typeof r.g...
function Gr (line 6) | function Gr(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMerged...
function qi (line 6) | function qi(e,n,t){var r=e.stateNode;if(!r)throw Error(h(169));t?(e=ka(e...
function Ea (line 6) | function Ea(e){Ve===null?Ve=[e]:Ve.push(e)}
function Ld (line 6) | function Ld(e){ml=!0,Ea(e)}
function hn (line 6) | function hn(){if(!no&&Ve!==null){no=!0;var e=0,n=T;try{var t=Ve;for(T=1;...
function gn (line 6) | function gn(e,n){Bn[Wn++]=Jr,Bn[Wn++]=Zr,Zr=e,Jr=n}
function _a (line 6) | function _a(e,n,t){ye[ge++]=Ae,ye[ge++]=He,ye[ge++]=Nn,Nn=e;var r=Ae;e=H...
function wu (line 6) | function wu(e){e.return!==null&&(gn(e,1),_a(e,1,0))}
function Su (line 6) | function Su(e){for(;e===Zr;)Zr=Bn[--Wn],Bn[Wn]=null,Jr=Bn[--Wn],Bn[Wn]=n...
function Ca (line 6) | function Ca(e,n){var t=we(5,null,null,0);t.elementType="DELETED",t.state...
function bi (line 6) | function bi(e,n){switch(e.tag){case 5:var t=e.type;return n=n.nodeType!=...
function Uo (line 6) | function Uo(e){return(e.mode&1)!==0&&(e.flags&128)===0}
function Vo (line 6) | function Vo(e){if(M){var n=fe;if(n){var t=n;if(!bi(e,n)){if(Uo(e))throw ...
function es (line 6) | function es(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13...
function Cr (line 6) | function Cr(e){if(e!==de)return!1;if(!M)return es(e),M=!0,!1;var n;if((n...
function xa (line 6) | function xa(){for(var e=fe;e;)e=un(e.nextSibling)}
function nt (line 6) | function nt(){fe=de=null,M=!1}
function ku (line 6) | function ku(e){Pe===null?Pe=[e]:Pe.push(e)}
function xe (line 6) | function xe(e,n){if(e&&e.defaultProps){n=j({},n),e=e.defaultProps;for(va...
function _u (line 6) | function _u(){Eu=$n=br=null}
function Cu (line 6) | function Cu(e){var n=qr.current;D(qr),e._currentValue=n}
function Ao (line 6) | function Ao(e,n,t){for(;e!==null;){var r=e.alternate;if((e.childLanes&n)...
function Jn (line 6) | function Jn(e,n){br=e,Eu=$n=null,e=e.dependencies,e!==null&&e.firstConte...
function ke (line 6) | function ke(e){var n=e._currentValue;if(Eu!==e)if(e={context:e,memoizedV...
function xu (line 6) | function xu(e){kn===null?kn=[e]:kn.push(e)}
function Na (line 6) | function Na(e,n,t,r){var l=n.interleaved;return l===null?(t.next=t,xu(n)...
function Qe (line 6) | function Qe(e,n){e.lanes|=n;var t=e.alternate;for(t!==null&&(t.lanes|=n)...
function Nu (line 6) | function Nu(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:...
function Pa (line 6) | function Pa(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={base...
function Be (line 6) | function Be(e,n){return{eventTime:e,lane:n,tag:0,payload:null,callback:n...
function sn (line 6) | function sn(e,n,t){var r=e.updateQueue;if(r===null)return null;if(r=r.sh...
function Or (line 6) | function Or(e,n,t){if(n=n.updateQueue,n!==null&&(n=n.shared,(t&4194240)!...
function ns (line 6) | function ns(e,n){var t=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.upd...
function el (line 6) | function el(e,n,t,r){var l=e.updateQueue;qe=!1;var o=l.firstBaseUpdate,u...
function ts (line 6) | function ts(e,n,t){if(e=n.effects,n.effects=null,e!==null)for(n=0;nt?t:4,e(!0);var r=ro.transition;ro.t...
function Xa (line 6) | function Xa(){return Ee().memoizedState}
function Md (line 6) | function Md(e,n,t){var r=cn(e);if(t={lane:r,action:t,hasEagerState:!1,ea...
function Id (line 6) | function Id(e,n,t){var r=cn(e),l={lane:r,action:t,hasEagerState:!1,eager...
function Ga (line 6) | function Ga(e){var n=e.alternate;return e===F||n!==null&&n===F}
function Za (line 6) | function Za(e,n){Tt=tl=!0;var t=e.pending;t===null?n.next=n:(n.next=t.ne...
function Ja (line 6) | function Ja(e,n,t){if(t&4194240){var r=n.lanes;r&=e.pendingLanes,t|=r,n....
function lt (line 6) | function lt(e,n){try{var t="",r=n;do t+=mf(r),r=r.return;while(r);var l=...
function uo (line 8) | function uo(e,n,t){return{value:e,source:null,stack:t??null,digest:n??nu...
function Wo (line 8) | function Wo(e,n){try{console.error(n.value)}catch(t){setTimeout(function...
function qa (line 8) | function qa(e,n,t){t=Be(-1,t),t.tag=3,t.payload={element:null};var r=n.v...
function ba (line 8) | function ba(e,n,t){t=Be(-1,t),t.tag=3;var r=e.type.getDerivedStateFromEr...
function ss (line 8) | function ss(e,n,t){var r=e.pingCache;if(r===null){r=e.pingCache=new Vd;v...
function as (line 8) | function as(e){do{var n;if((n=e.tag===13)&&(n=e.memoizedState,n=n!==null...
function cs (line 8) | function cs(e,n,t,r,l){return e.mode&1?(e.flags|=65536,e.lanes=l,e):(e==...
function te (line 8) | function te(e,n,t,r){n.child=e===null?Ra(n,null,t,r):tt(n,e.child,t,r)}
function fs (line 8) | function fs(e,n,t,r,l){t=t.render;var o=n.ref;return Jn(n,l),r=Ru(e,n,t,...
function ds (line 8) | function ds(e,n,t,r,l){if(e===null){var o=t.type;return typeof o=="funct...
function ec (line 8) | function ec(e,n,t,r,l){if(e!==null){var o=e.memoizedProps;if(At(o,r)&&e....
function nc (line 8) | function nc(e,n,t){var r=n.pendingProps,l=r.children,o=e!==null?e.memoiz...
function tc (line 8) | function tc(e,n){var t=n.ref;(e===null&&t!==null||e!==null&&e.ref!==t)&&...
function $o (line 8) | function $o(e,n,t,r,l){var o=se(t)?xn:ee.current;return o=et(n,o),Jn(n,l...
function ps (line 8) | function ps(e,n,t,r,l){if(se(t)){var o=!0;Gr(n)}else o=!1;if(Jn(n,l),n.s...
function Qo (line 8) | function Qo(e,n,t,r,l,o){tc(e,n);var u=(n.flags&128)!==0;if(!r&&!u)retur...
function rc (line 8) | function rc(e){var n=e.stateNode;n.pendingContext?Ji(e,n.pendingContext,...
function ms (line 8) | function ms(e,n,t,r,l){return nt(),ku(l),n.flags|=256,te(e,n,t,r),n.child}
function Yo (line 8) | function Yo(e){return{baseLanes:e,cachePool:null,transitions:null}}
function lc (line 8) | function lc(e,n,t){var r=n.pendingProps,l=I.current,o=!1,u=(n.flags&128)...
function Iu (line 8) | function Iu(e,n){return n=wl({mode:"visible",children:n},e.mode,0,null),...
function Nr (line 8) | function Nr(e,n,t,r){return r!==null&&ku(r),tt(n,e.child,null,t),e=Iu(n,...
function Hd (line 8) | function Hd(e,n,t,r,l,o,u){if(t)return n.flags&256?(n.flags&=-257,r=uo(E...
function vs (line 8) | function vs(e,n,t){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n),A...
function io (line 8) | function io(e,n,t,r,l){var o=e.memoizedState;o===null?e.memoizedState={i...
function oc (line 8) | function oc(e,n,t){var r=n.pendingProps,l=r.revealOrder,o=r.tail;if(te(e...
function Ir (line 8) | function Ir(e,n){!(n.mode&1)&&e!==null&&(e.alternate=null,n.alternate=nu...
function Ke (line 8) | function Ke(e,n,t){if(e!==null&&(n.dependencies=e.dependencies),zn|=n.la...
function Bd (line 8) | function Bd(e,n,t){switch(n.tag){case 3:rc(n),nt();break;case 5:Oa(n);br...
function yt (line 8) | function yt(e,n){if(!M)switch(e.tailMode){case"hidden":n=e.tail;for(var ...
function q (line 8) | function q(e){var n=e.alternate!==null&&e.alternate.child===e.child,t=0,...
function Wd (line 8) | function Wd(e,n,t){var r=n.pendingProps;switch(Su(n),n.tag){case 2:case ...
function $d (line 8) | function $d(e,n){switch(Su(n),n.tag){case 1:return se(n.type)&&Xr(),e=n....
function Qn (line 8) | function Qn(e,n){var t=e.ref;if(t!==null)if(typeof t=="function")try{t(n...
function Go (line 8) | function Go(e,n,t){try{t()}catch(r){U(e,n,r)}}
function Kd (line 8) | function Kd(e,n){if(Oo=$r,e=da(),gu(e)){if("selectionStart"in e)var t={s...
function Lt (line 8) | function Lt(e,n,t){var r=n.updateQueue;if(r=r!==null?r.lastEffect:null,r...
function yl (line 8) | function yl(e,n){if(n=n.updateQueue,n=n!==null?n.lastEffect:null,n!==nul...
function Zo (line 8) | function Zo(e){var n=e.ref;if(n!==null){var t=e.stateNode;switch(e.tag){...
function ac (line 8) | function ac(e){var n=e.alternate;n!==null&&(e.alternate=null,ac(n)),e.ch...
function cc (line 8) | function cc(e){return e.tag===5||e.tag===3||e.tag===4}
function ys (line 8) | function ys(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||cc(...
function Jo (line 8) | function Jo(e,n,t){var r=e.tag;if(r===5||r===6)e=e.stateNode,n?t.nodeTyp...
function qo (line 8) | function qo(e,n,t){var r=e.tag;if(r===5||r===6)e=e.stateNode,n?t.insertB...
function Ze (line 8) | function Ze(e,n,t){for(t=t.child;t!==null;)fc(e,n,t),t=t.sibling}
function fc (line 8) | function fc(e,n,t){if(Ie&&typeof Ie.onCommitFiberUnmount=="function")try...
function gs (line 8) | function gs(e){var n=e.updateQueue;if(n!==null){e.updateQueue=null;var t...
function Ce (line 8) | function Ce(e,n){var t=n.deletions;if(t!==null)for(var r=0;r"u"||typeof __R...
function Rc (line 8) | function Rc(e,n,t){var r,l={},o=null,u=null;t!==void 0&&(o=""+t),n.key!=...
function gp (line 8) | function gp(e){let n=e.getAttribute("data-name")??"";(0,xl.createRoot)(e...
FILE: examples/internationalization/components_templ.go
function page (line 12) | func page() templ.Component {
FILE: examples/internationalization/main.go
function newLanguageMiddleware (line 13) | func newLanguageMiddleware(next http.Handler) http.Handler {
function main (line 30) | func main() {
FILE: examples/static-generator/blog_templ.go
function headerComponent (line 15) | func headerComponent(title string) templ.Component {
function contentComponent (line 57) | func contentComponent(title string, body templ.Component) templ.Component {
function contentPage (line 107) | func contentPage(title string, body templ.Component) templ.Component {
function indexPage (line 148) | func indexPage(posts []Post) templ.Component {
FILE: examples/static-generator/main.go
type Post (line 17) | type Post struct
function Unsafe (line 23) | func Unsafe(html string) templ.Component {
function main (line 30) | func main() {
FILE: examples/streaming/main_templ.go
function main (line 16) | func main() {
function Page (line 45) | func Page(data chan string) templ.Component {
FILE: examples/suspense/main_templ.go
function main (line 16) | func main() {
type SlotContents (line 71) | type SlotContents struct
function Slot (line 76) | func Slot(name string) templ.Component {
function A (line 131) | func A() templ.Component {
function B (line 160) | func B() templ.Component {
function C (line 189) | func C() templ.Component {
function Page (line 218) | func Page(data chan SlotContents) templ.Component {
FILE: examples/syntax-and-usage/components/main.go
function main (line 14) | func main() {
function codeList (line 24) | func codeList(items []string) templ.Component {
FILE: examples/syntax-and-usage/components/templsyntax_templ.go
function list (line 10) | func list(items []string) templ.Component {
FILE: examples/typescript/assets/js/index.js
function a (line 1) | function a(){let t=document.querySelector("#attributeAlerter");t&&t.addE...
function c (line 1) | function c(){let t=document.querySelector("#scriptAlerter");t&&t.addEven...
FILE: examples/typescript/components/index_templ.go
type Data (line 10) | type Data struct
function Page (line 14) | func Page(attributeData Data, scriptData Data) templ.Component {
FILE: examples/typescript/main.go
function main (line 11) | func main() {
FILE: examples/typescript/ts/src/index.ts
type Data (line 5) | interface Data {
function setupAttributeAlerter (line 9) | function setupAttributeAlerter() {
function setupScriptAlerter (line 21) | function setupScriptAlerter() {
FILE: flush.go
function Flush (line 9) | func Flush() FlushComponent {
type FlushComponent (line 13) | type FlushComponent struct
method Render (line 24) | func (f FlushComponent) Render(ctx context.Context, w io.Writer) (err ...
type flusherError (line 16) | type flusherError interface
type flusher (line 20) | type flusher interface
FILE: flush_test.go
type flushableErrorWriter (line 11) | type flushableErrorWriter struct
method Write (line 18) | func (f *flushableErrorWriter) Write(p []byte) (n int, err error) {
method Flush (line 30) | func (f *flushableErrorWriter) Flush() error {
type flushableWriter (line 36) | type flushableWriter struct
method Write (line 43) | func (f *flushableWriter) Write(p []byte) (n int, err error) {
method Flush (line 55) | func (f *flushableWriter) Flush() {
function TestFlush (line 60) | func TestFlush(t *testing.T) {
FILE: fragment.go
function RenderFragments (line 10) | func RenderFragments(ctx context.Context, w io.Writer, c Component, ids ...
type fragmentContextKeyType (line 18) | type fragmentContextKeyType
constant fragmentContextKey (line 20) | fragmentContextKey fragmentContextKeyType = iota
type FragmentContext (line 23) | type FragmentContext struct
function Fragment (line 32) | func Fragment(id any) Component {
type fragment (line 38) | type fragment struct
method Render (line 42) | func (f *fragment) Render(ctx context.Context, w io.Writer) (err error) {
function getFragmentContext (line 60) | func getFragmentContext(ctx context.Context) *FragmentContext {
FILE: fragment_test.go
function TestFragment (line 12) | func TestFragment(t *testing.T) {
FILE: generator/generator.go
type GenerateOpt (line 22) | type GenerateOpt
function WithVersion (line 25) | func WithVersion(v string) GenerateOpt {
function WithTimestamp (line 33) | func WithTimestamp(d time.Time) GenerateOpt {
function WithFileName (line 41) | func WithFileName(name string) GenerateOpt {
function WithSkipCodeGeneratedComment (line 55) | func WithSkipCodeGeneratedComment() GenerateOpt {
type GeneratorOutput (line 62) | type GeneratorOutput struct
type GeneratorOptions (line 68) | type GeneratorOptions struct
function HasGoChanged (line 80) | func HasGoChanged(previous, updated GeneratorOutput) bool {
function HasTextChanged (line 109) | func HasTextChanged(previous, updated GeneratorOutput) bool {
function Generate (line 123) | func Generate(template *parser.TemplateFile, w io.Writer, opts ...Genera...
type generator (line 144) | type generator struct
method generate (line 154) | func (g *generator) generate() (err error) {
method writeCodeGeneratedComment (line 185) | func (g *generator) writeCodeGeneratedComment() (err error) {
method writeVersionComment (line 195) | func (g *generator) writeVersionComment() (err error) {
method writeGeneratedDateComment (line 202) | func (g *generator) writeGeneratedDateComment() (err error) {
method writeHeader (line 209) | func (g *generator) writeHeader() (err error) {
method writePackage (line 221) | func (g *generator) writePackage() error {
method writeImports (line 235) | func (g *generator) writeImports() error {
method writeTemplateNodes (line 250) | func (g *generator) writeTemplateNodes() error {
method writeCSS (line 276) | func (g *generator) writeCSS(n *parser.CSSTemplate) error {
method writeGoExpression (line 363) | func (g *generator) writeGoExpression(n *parser.TemplateFileGoExpressi...
method writeTemplBuffer (line 395) | func (g *generator) writeTemplBuffer(indentLevel int) (err error) {
method writeTemplate (line 447) | func (g *generator) writeTemplate(nodeIdx int, t *parser.HTMLTemplate)...
method writeNodes (line 592) | func (g *generator) writeNodes(indentLevel int, nodes []parser.Node, n...
method writeNode (line 608) | func (g *generator) writeNode(indentLevel int, current parser.Node, ne...
method writeWhitespaceTrailer (line 683) | func (g *generator) writeWhitespaceTrailer(indentLevel int, n parser.T...
method writeDocType (line 698) | func (g *generator) writeDocType(indentLevel int, n *parser.DocType) (...
method writeFallthrough (line 705) | func (g *generator) writeFallthrough(indentLevel int) (err error) {
method writeIfExpression (line 715) | func (g *generator) writeIfExpression(indentLevel int, n *parser.IfExp...
method writeSwitchExpression (line 779) | func (g *generator) writeSwitchExpression(indentLevel int, n *parser.S...
method writeChildrenExpression (line 817) | func (g *generator) writeChildrenExpression(indentLevel int) (err erro...
method writeTemplElementExpression (line 827) | func (g *generator) writeTemplElementExpression(indentLevel int, n *pa...
method writeBlockTemplElementExpression (line 834) | func (g *generator) writeBlockTemplElementExpression(indentLevel int, ...
method writeSelfClosingTemplElementExpression (line 879) | func (g *generator) writeSelfClosingTemplElementExpression(indentLevel...
method writeCallTemplateExpression (line 899) | func (g *generator) writeCallTemplateExpression(indentLevel int, n *pa...
method writeForExpression (line 919) | func (g *generator) writeForExpression(indentLevel int, n *parser.ForE...
method writeErrorHandler (line 947) | func (g *generator) writeErrorHandler(indentLevel int) (err error) {
method writeExpressionErrorHandler (line 965) | func (g *generator) writeExpressionErrorHandler(indentLevel int, expre...
method writeElement (line 985) | func (g *generator) writeElement(indentLevel int, n *parser.Element) (...
method writeAttributeCSS (line 1028) | func (g *generator) writeAttributeCSS(indentLevel int, attr *parser.Ex...
method writeAttributesCSS (line 1069) | func (g *generator) writeAttributesCSS(indentLevel int, attrs []parser...
method writeElementCSS (line 1095) | func (g *generator) writeElementCSS(indentLevel int, attrs []parser.At...
method writeElementScript (line 1108) | func (g *generator) writeElementScript(indentLevel int, attrs []parser...
method writeAttributeKey (line 1145) | func (g *generator) writeAttributeKey(indentLevel int, attr parser.Att...
method writeBoolConstantAttribute (line 1188) | func (g *generator) writeBoolConstantAttribute(indentLevel int, attr *...
method writeConstantAttribute (line 1192) | func (g *generator) writeConstantAttribute(indentLevel int, attr *pars...
method writeBoolExpressionAttribute (line 1214) | func (g *generator) writeBoolExpressionAttribute(indentLevel int, attr...
method writeExpressionAttributeValueURL (line 1243) | func (g *generator) writeExpressionAttributeValueURL(indentLevel int, ...
method writeExpressionAttributeValueScript (line 1275) | func (g *generator) writeExpressionAttributeValueScript(indentLevel in...
method writeExpressionAttributeValueDefault (line 1297) | func (g *generator) writeExpressionAttributeValueDefault(indentLevel i...
method writeExpressionAttributeValueStyle (line 1330) | func (g *generator) writeExpressionAttributeValueStyle(indentLevel int...
method writeExpressionAttribute (line 1363) | func (g *generator) writeExpressionAttribute(indentLevel int, elementN...
method writeSpreadAttributes (line 1397) | func (g *generator) writeSpreadAttributes(indentLevel int, attr *parse...
method writeConditionalAttribute (line 1418) | func (g *generator) writeConditionalAttribute(indentLevel int, element...
method writeElementAttributes (line 1460) | func (g *generator) writeElementAttributes(indentLevel int, name strin...
method writeRawElement (line 1482) | func (g *generator) writeRawElement(indentLevel int, n *parser.RawElem...
method writeScriptElement (line 1516) | func (g *generator) writeScriptElement(indentLevel int, n *parser.Scri...
method writeScriptContents (line 1552) | func (g *generator) writeScriptContents(indentLevel int, c parser.Scri...
method writeComment (line 1610) | func (g *generator) writeComment(indentLevel int, c *parser.HTMLCommen...
method createVariableName (line 1626) | func (g *generator) createVariableName() string {
method writeGoCode (line 1631) | func (g *generator) writeGoCode(indentLevel int, e parser.Expression) ...
method writeStringExpression (line 1643) | func (g *generator) writeStringExpression(indentLevel int, e parser.Ex...
method writeWhitespace (line 1683) | func (g *generator) writeWhitespace(indentLevel int, n *parser.Whitesp...
method writeText (line 1694) | func (g *generator) writeText(indentLevel int, n *parser.Text) (err er...
method writeScript (line 1713) | func (g *generator) writeScript(t *parser.ScriptTemplate) error {
method writeBlankAssignmentForRuntimeImport (line 1794) | func (g *generator) writeBlankAssignmentForRuntimeImport() error {
function stripWhitespace (line 560) | func stripWhitespace(input []parser.Node) (output []parser.Node) {
function stripLeadingWhitespace (line 569) | func stripLeadingWhitespace(nodes []parser.Node) []parser.Node {
function stripTrailingWhitespace (line 578) | func stripTrailingWhitespace(nodes []parser.Node) []parser.Node {
function stripLeadingAndTrailingWhitespace (line 588) | func stripLeadingAndTrailingWhitespace(nodes []parser.Node) []parser.Node {
function isInlineOrText (line 660) | func isInlineOrText(next parser.Node) bool {
function escapeQuotes (line 710) | func escapeQuotes(s string) string {
function isScriptAttribute (line 1099) | func isScriptAttribute(name string) bool {
function getAttributeScripts (line 1127) | func getAttributeScripts(attr parser.Attribute) (scripts []string) {
function createGoString (line 1699) | func createGoString(s string) string {
function functionName (line 1802) | func functionName(name string, body string) string {
function stripTypes (line 1809) | func stripTypes(parameters string) string {
function isExpressionAttributeValueURL (line 1819) | func isExpressionAttributeValueURL(elementName, attrName string) bool {
FILE: generator/generator_test.go
function TestGeneratorSourceMap (line 11) | func TestGeneratorSourceMap(t *testing.T) {
function TestGeneratorForLSP (line 51) | func TestGeneratorForLSP(t *testing.T) {
function TestIsExpressionAttributeValueURL (line 74) | func TestIsExpressionAttributeValueURL(t *testing.T) {
FILE: generator/htmldiff/diff.go
function DiffStrings (line 14) | func DiffStrings(expected, actual string) (output, diff string, err erro...
function Diff (line 44) | func Diff(input templ.Component, expected string) (actual, diff string, ...
function DiffCtx (line 48) | func DiffCtx(ctx context.Context, input templ.Component, expected string...
FILE: generator/rangewriter.go
function NewRangeWriter (line 12) | func NewRangeWriter(w io.Writer) *RangeWriter {
type RangeWriter (line 19) | type RangeWriter struct
method closeLiteral (line 30) | func (rw *RangeWriter) closeLiteral(indent int) (r parser.Range, err e...
method WriteIndent (line 54) | func (rw *RangeWriter) WriteIndent(level int, s string) (r parser.Rang...
method WriteStringLiteral (line 67) | func (rw *RangeWriter) WriteStringLiteral(level int, s string) (r pars...
method Write (line 73) | func (rw *RangeWriter) Write(s string) (r parser.Range, err error) {
method write (line 82) | func (rw *RangeWriter) write(s string) (r parser.Range, err error) {
method writeErrorHandler (line 106) | func (rw *RangeWriter) writeErrorHandler(indentLevel int) (err error) {
FILE: generator/rangewriter_test.go
function TestRangeWriter (line 11) | func TestRangeWriter(t *testing.T) {
FILE: generator/test-a-href/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-a-href/template_templ.go
function render (line 10) | func render() templ.Component {
FILE: generator/test-attribute-errors/render_test.go
function Test (line 17) | func Test(t *testing.T) {
FILE: generator/test-attribute-errors/template_templ.go
function funcWithNoError (line 10) | func funcWithNoError() (s string) {
function funcWithError (line 14) | func funcWithError(in error) (s string, err error) {
function TestComponent (line 21) | func TestComponent(err error) templ.Component {
FILE: generator/test-attribute-escaping/render_test.go
function Test (line 15) | func Test(t *testing.T) {
FILE: generator/test-attribute-escaping/template_templ.go
function BasicTemplate (line 10) | func BasicTemplate(url string) templ.Component {
FILE: generator/test-call/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-call/template_templ.go
function showAll (line 10) | func showAll() templ.Component {
function a (line 73) | func a() templ.Component {
function b (line 102) | func b(child templ.Component) templ.Component {
function c (line 135) | func c(text string) templ.Component {
function d (line 177) | func d() templ.Component {
function e (line 206) | func e() templ.Component {
function showOne (line 235) | func showOne(component templ.Component) templ.Component {
function wrapChildren (line 272) | func wrapChildren() templ.Component {
FILE: generator/test-cancelled-context/render_test.go
function Test (line 9) | func Test(t *testing.T) {
FILE: generator/test-cancelled-context/template_templ.go
function EmptyComponent (line 10) | func EmptyComponent() templ.Component {
FILE: generator/test-class-whitespace/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-class-whitespace/template_templ.go
function MultilineClassAttribute (line 11) | func MultilineClassAttribute() templ.Component {
function ExtraSpaces (line 40) | func ExtraSpaces() templ.Component {
function LeadingTrailingSpaces (line 69) | func LeadingTrailingSpaces() templ.Component {
function TabsAndNewlines (line 98) | func TabsAndNewlines() templ.Component {
function CaseInsensitive (line 127) | func CaseInsensitive() templ.Component {
function OtherAttributesUnchanged (line 156) | func OtherAttributesUnchanged() templ.Component {
function TestComponent (line 185) | func TestComponent() templ.Component {
FILE: generator/test-complex-attributes/render_test.go
function Test (line 15) | func Test(t *testing.T) {
FILE: generator/test-complex-attributes/template_templ.go
function ComplexAttributes (line 10) | func ComplexAttributes() templ.Component {
FILE: generator/test-constant-attribute-escaping/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-constant-attribute-escaping/template_templ.go
function BasicTemplate (line 10) | func BasicTemplate() templ.Component {
FILE: generator/test-context/render_test.go
function Test (line 16) | func Test(t *testing.T) {
FILE: generator/test-context/template_templ.go
type contextKey (line 10) | type contextKey
function render (line 14) | func render() templ.Component {
FILE: generator/test-css-expression/constants.go
constant red (line 3) | red = "#ff0000"
FILE: generator/test-css-expression/render_test.go
function TestCSSExpression (line 15) | func TestCSSExpression(t *testing.T) {
FILE: generator/test-css-expression/template_templ.go
function className (line 10) | func className() templ.CSSClass {
FILE: generator/test-css-middleware/render_test.go
function Test (line 22) | func Test(t *testing.T) {
FILE: generator/test-css-middleware/template_templ.go
function red (line 10) | func red() templ.CSSClass {
function render (line 20) | func render(s string) templ.Component {
FILE: generator/test-css-usage/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-css-usage/template_templ.go
function StyleTagsAreSupported (line 15) | func StyleTagsAreSupported() templ.Component {
constant red (line 46) | red = "#00ff00"
function cssComponentGreen (line 48) | func cssComponentGreen() templ.CSSClass {
function CSSComponentsAreSupported (line 58) | func CSSComponentsAreSupported() templ.Component {
function CSSComponentsAndConstantsAreSupported (line 107) | func CSSComponentsAndConstantsAreSupported() templ.Component {
function MapsCanBeUsedToConditionallySetClasses (line 177) | func MapsCanBeUsedToConditionallySetClasses() templ.Component {
function d (line 225) | func d() templ.CSSClass {
function e (line 235) | func e() templ.CSSClass {
function KVCanBeUsedToConditionallySetClasses (line 245) | func KVCanBeUsedToConditionallySetClasses() templ.Component {
function PseudoAttributesAndComplexClassNamesAreSupported (line 293) | func PseudoAttributesAndComplexClassNamesAreSupported() templ.Component {
function ClassNamesAreHTMLEscaped (line 341) | func ClassNamesAreHTMLEscaped() templ.Component {
function loading (line 389) | func loading(percent int) templ.CSSClass {
function CSSComponentsCanBeUsedWithArguments (line 399) | func CSSComponentsCanBeUsedWithArguments() templ.Component {
function windVaneRotation (line 468) | func windVaneRotation(degrees float64) templ.CSSClass {
function Rotate (line 478) | func Rotate(degrees float64) templ.Component {
function TestComponent (line 526) | func TestComponent() templ.Component {
FILE: generator/test-doctype-html4/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-doctype-html4/template_templ.go
function Layout (line 10) | func Layout(title, content string) templ.Component {
FILE: generator/test-doctype/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-doctype/template_templ.go
function Layout (line 10) | func Layout(title, content string) templ.Component {
FILE: generator/test-element-attributes/data.go
type person (line 3) | type person struct
FILE: generator/test-element-attributes/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-element-attributes/template_templ.go
function important (line 10) | func important() templ.CSSClass {
function unimportant (line 20) | func unimportant() templ.CSSClass {
function render (line 30) | func render(p person) templ.Component {
FILE: generator/test-elseif/data.go
type data (line 3) | type data struct
method IsTrue (line 6) | func (d data) IsTrue() bool {
FILE: generator/test-elseif/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-elseif/template_templ.go
function render (line 10) | func render(d data) templ.Component {
FILE: generator/test-for/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-for/template_templ.go
function render (line 10) | func render(items []string) templ.Component {
FILE: generator/test-form-action/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-form-action/template_templ.go
function render (line 10) | func render() templ.Component {
function safeUrl (line 91) | func safeUrl(s string) (templ.SafeURL, error) {
function stringUrl (line 95) | func stringUrl(s string) (string, error) {
FILE: generator/test-fragment/render_test.go
function Test (line 19) | func Test(t *testing.T) {
FILE: generator/test-fragment/template_templ.go
function Page (line 10) | func Page() templ.Component {
FILE: generator/test-go-comments/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-go-comments/template_templ.go
function render (line 10) | func render(content string) templ.Component {
FILE: generator/test-go-template-in-templ/render_test.go
function TestExample (line 14) | func TestExample(t *testing.T) {
FILE: generator/test-go-template-in-templ/template_templ.go
function Example (line 14) | func Example() templ.Component {
FILE: generator/test-html-comment/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-html-comment/template_templ.go
function render (line 10) | func render(content string) templ.Component {
function paragraph (line 76) | func paragraph(content string) templ.Component {
FILE: generator/test-html/data.go
type person (line 3) | type person struct
FILE: generator/test-html/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-html/template_templ.go
function render (line 10) | func render(p person) templ.Component {
FILE: generator/test-if/data.go
type data (line 3) | type data struct
method IsTrue (line 6) | func (d data) IsTrue() bool {
FILE: generator/test-if/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-if/template_templ.go
function render (line 10) | func render(d data) templ.Component {
FILE: generator/test-ifelse/data.go
type data (line 3) | type data struct
method IsTrue (line 6) | func (d data) IsTrue() bool {
FILE: generator/test-ifelse/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-ifelse/template_templ.go
function render (line 10) | func render(d data) templ.Component {
FILE: generator/test-import/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-import/template_templ.go
function listItem (line 10) | func listItem() templ.Component {
function list (line 47) | func list() templ.Component {
function main (line 84) | func main() templ.Component {
FILE: generator/test-js-unsafe-usage/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-js-unsafe-usage/template_templ.go
function TestComponent (line 10) | func TestComponent() templ.Component {
FILE: generator/test-js-usage/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-js-usage/template_templ.go
function TestComponent (line 14) | func TestComponent() templ.Component {
FILE: generator/test-method/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-method/template_templ.go
type Data (line 10) | type Data struct
method Method (line 14) | func (d Data) Method() templ.Component {
FILE: generator/test-once/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-once/template_templ.go
function hello (line 12) | func hello(label, name string) templ.Component {
function render (line 89) | func render() templ.Component {
FILE: generator/test-only-scripts/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-only-scripts/template_templ.go
function withParameters (line 10) | func withParameters(a string, b string, c int) templ.ComponentScript {
FILE: generator/test-primitives/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-primitives/template_templ.go
function render (line 10) | func render() templ.Component {
type stringish (line 273) | type stringish
FILE: generator/test-raw-elements/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-raw-elements/template_templ.go
function Example (line 10) | func Example() templ.Component {
FILE: generator/test-script-expressions/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-script-expressions/template_templ.go
function Script (line 10) | func Script[T any](name string, data T) templ.Component {
function AllTests (line 112) | func AllTests() templ.Component {
FILE: generator/test-script-inline/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-script-inline/template_templ.go
function withParameters (line 10) | func withParameters(a string, b string, c int) templ.ComponentScript {
function withoutParameters (line 20) | func withoutParameters() templ.ComponentScript {
function InlineJavascript (line 30) | func InlineJavascript(a string) templ.Component {
FILE: generator/test-script-usage-nonce/render_test.go
function Test (line 15) | func Test(t *testing.T) {
FILE: generator/test-script-usage-nonce/template_templ.go
function withParameters (line 10) | func withParameters(a string, b string, c int) templ.ComponentScript {
function withoutParameters (line 20) | func withoutParameters() templ.ComponentScript {
function onClick (line 30) | func onClick() templ.ComponentScript {
function Button (line 40) | func Button(text string) templ.Component {
function withComment (line 104) | func withComment() templ.ComponentScript {
function ThreeButtons (line 114) | func ThreeButtons() templ.Component {
function conditionalScript (line 172) | func conditionalScript() templ.ComponentScript {
function Conditional (line 182) | func Conditional(show bool) templ.Component {
FILE: generator/test-script-usage/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-script-usage/template_templ.go
function withParameters (line 10) | func withParameters(a string, b string, c int) templ.ComponentScript {
function withoutParameters (line 20) | func withoutParameters() templ.ComponentScript {
function onClick (line 30) | func onClick() templ.ComponentScript {
function Button (line 40) | func Button(text string) templ.Component {
function withComment (line 104) | func withComment() templ.ComponentScript {
function whenButtonIsClicked (line 114) | func whenButtonIsClicked(event templ.JSExpression) templ.ComponentScript {
function ThreeButtons (line 124) | func ThreeButtons() templ.Component {
function conditionalScript (line 203) | func conditionalScript() templ.ComponentScript {
function Conditional (line 213) | func Conditional(show bool) templ.Component {
function alertTest (line 265) | func alertTest() templ.ComponentScript {
function ScriptOnLoad (line 275) | func ScriptOnLoad() templ.Component {
FILE: generator/test-spread-attributes/render_test.go
function Test (line 16) | func Test(t *testing.T) {
function TestOrderedAttributes (line 67) | func TestOrderedAttributes(t *testing.T) {
function nilPtr (line 115) | func nilPtr[T any]() *T {
function ptr (line 119) | func ptr[T any](x T) *T {
function TestNumericAttributeTypes (line 126) | func TestNumericAttributeTypes(t *testing.T) {
FILE: generator/test-spread-attributes/template_templ.go
function BasicTemplate (line 10) | func BasicTemplate(spread templ.Attributes) templ.Component {
function BasicTemplateOrdered (line 67) | func BasicTemplateOrdered(spread templ.OrderedAttributes) templ.Component {
FILE: generator/test-string-errors/render_test.go
function Test (line 17) | func Test(t *testing.T) {
FILE: generator/test-string-errors/template_templ.go
function funcWithNoError (line 10) | func funcWithNoError() (s string) {
function funcWithError (line 14) | func funcWithError(in error) (s string, err error) {
function TestComponent (line 21) | func TestComponent(err error) templ.Component {
FILE: generator/test-string/render_test.go
function Test (line 14) | func Test(t *testing.T) {
FILE: generator/test-string/template_templ.go
function render (line 10) | func render(s string) templ.Component {
FILE: generator/test-style-attribute/render_test.go
function Test (line 16) | func Test(t *testing.T) {
FILE: generator/test-style-attribute/template_templ.go
function Button (line 10) | func Button[T any](style T, text string) templ.Component {
function getFunctionResult (line 91) | func getFunctionResult() (string, error) {
FILE: generator/test-switch/render_test.go
constant expected (line 13) | expected = `it was 'a'`
function TestRender (line 15) | func TestRender(t *testing.T) {
FILE: generator/test-switch/template_templ.go
function render (line 10) | func render(input string) templ.Component {
FILE: generator/test-switchdefault/render_test.go
constant expected (line 13) | expected = `it was something else`
function TestRender (line 15) | func TestRender(t *testing.T) {
FILE: generator/test-switchdefault/template_templ.go
function template (line 10) | func template(input string) templ.Component {
FILE: generator/test-templ-element/render_test.go
function Test (line 15) | func Test(t *testing.T) {
FILE: generator/test-templ-element/template_templ.go
function wrapper (line 12) | func wrapper(index int) templ.Component {
function template (line 62) | func template() templ.Component {
FILE: generator/test-templ-in-go-template/render_test.go
function TestExample (line 17) | func TestExample(t *testing.T) {
FILE: generator/test-templ-in-go-template/template_templ.go
function greeting (line 20) | func greeting() templ.Component {
FILE: generator/test-text-whitespace/render_test.go
function TestTextWhitespace (line 12) | func TestTextWhitespace(t *testing.T) {
FILE: generator/test-text-whitespace/template_templ.go
function WhitespaceIsAddedWithinTemplStatements (line 10) | func WhitespaceIsAddedWithinTemplStatements() templ.Component {
constant WhitespaceIsAddedWithinTemplStatementsExpected (line 49) | WhitespaceIsAddedWithinTemplStatementsExpected = `
This is some text. ...
function InlineElementsAreNotPadded (line 51) | func InlineElementsAreNotPadded() templ.Component {
constant InlineElementsAreNotPaddedExpected (line 80) | InlineElementsAreNotPaddedExpected = `
Inline text is spaced proper...
function WhiteSpaceInHTMLIsNormalised (line 82) | func WhiteSpaceInHTMLIsNormalised() templ.Component {
constant WhiteSpaceInHTMLIsNormalisedExpected (line 111) | WhiteSpaceInHTMLIsNormalisedExpected = `
newlines and other whitespace...
function WhiteSpaceAroundValues (line 113) | func WhiteSpaceAroundValues() templ.Component {
constant WhiteSpaceAroundValuesExpected (line 155) | WhiteSpaceAroundValuesExpected = `
templ allows strings to be included...
constant WhiteSpaceAroundTemplatedValuesExpected (line 157) | WhiteSpaceAroundTemplatedValuesExpected = `