First commit

This commit is contained in:
2025-11-17 13:34:43 -06:00
commit bde690c9cb
36 changed files with 1363 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
func WebAppMain(args)
{
return (ctx)=>{
if(ctx.Path == "/")
{
ctx.WithMimeType("text/html").SendText(<img src="mountain.jpg">);
return true;
}
else if(ctx.Path == "/mountain.jpg")
{
var mypicture = embed("mountain.jpg");
ctx.WithMimeType("image/jpeg").SendBytes(mypicture);
return true;
}
return false;
};
}
func main(args)
{
Console.WriteLine("use crosslang webapp-test to test");
}