// BRY Web starter: edit this file to build your own application. // Request: path, name. Response: status, content type, body. #@+8.5.7(@1#3,@2#3) #@+8.5.+9(@1#1,@2#3,@3#3) ::2.+8.++5.5.+9.3(@1#3)#3 [ @2 := "" @3 := 0 @4 := "" !(:len(@1) <= 512) ~(:len(@1))[ @4 := @1[@3] ?(@4 == "&")[@2 := @2 + "&"]:[ ?(@4 == "<")[@2 := @2 + "<"]:[ ?(@4 == ">")[@2 := @2 + ">"]:[ ?(@4 == "\"")[@2 := @2 + """]:[ ?(@4 == "'")[@2 := @2 + "'"]:[@2 := @2 + @4] ] ] ] ] @3 := @3 + 1 ] < @2 ] ::2.+8.++5.4.+5.3(@1#3,@2#3)#3 [ < "
BRY / STARTER 01
Every page in this project is rendered by a Bry program. Edit the symbolic source and make it yours.
Explore the project")) ] ?(@2 == "/about")[ < #@+8.5.+9(200,"text/html",::2.+8.++5.4.+5.3("About","01 / SOURCE
This reusable project has a local server, a static build and a Cloudflare worker export. The source language stays Bry.
")) ] ?(@2 == "/hello")[ ?(:len(@3) == 0)[@3 := "Visitor"] < #@+8.5.+9(200,"text/html",::2.+8.++5.4.+5.3("Hello","02 / DYNAMIC ROUTE
Try a different name. Dynamic mode executes Bry for each request; static mode renders the default greeting.
")) ] < #@+8.5.+9(404,"text/html",::2.+8.++5.4.+5.3("Not found","