maxence-charriere/go-app: A package to build ... - GitHub

文章推薦指數: 80 %
投票人數:10人

Go-app is a package for building progressive web apps (PWA) with the Go programming language (Golang) and WebAssembly (Wasm). Shaping a UI is done by using ... Skiptocontent {{message}} maxence-charriere / go-app Public Notifications Star 5.6k Fork 261 ApackagetobuildprogressivewebappswithGoprogramminglanguageandWebAssembly. go-app.dev MITLicense 5.6k stars 261 forks Star Notifications Code Issues 31 Pullrequests 7 Actions Projects 0 Wiki Security Insights More Code Issues Pullrequests Actions Projects Wiki Security Insights master Branches Tags Couldnotloadbranches Nothingtoshow Loading {{refName}} default Couldnotloadtags Nothingtoshow {{refName}} default Loading 10 branches 99 tags Code Loading Latestcommit maxence-charriere FixUI(#649) … 7167a6b Dec1,2021 FixUI(#649) *Updatecomponent.go *Updateflow.go *Updateflow.go *Updateshell.go *Updateshell.go *resizeshell *Updateflow.go 7167a6b Gitstats 1,075 commits Files Permalink Failedtoloadlatestcommitinformation. Type Name Latestcommitmessage Committime .circleci V9(#588) Sep22,2021 .github UpdateFUNDING.yml Jun1,2020 docs updatedocsbuildwith Nov11,2021 pkg FixUI(#649) Dec1,2021 .gitattributes Refactorwindowwip Feb9,2018 .gitignore Fixdocssetup Jul9,2020 CODE_OF_CONDUCT.md CreateCODE_OF_CONDUCT.md Feb23,2018 CONTRIBUTING.md Updatereadmecontributorsection(#375) Apr6,2020 LICENSE driverlogic+contextlogic Oct23,2016 README.md fixlinkinreadme(#600) Sep30,2021 go.mod V9(#588) Sep22,2021 go.sum V9(#588) Sep22,2021 makefile Fixreference(#626) Oct25,2021 Viewcode Documentation(builtwithgo-app) Install Declarativesyntax StandardHTTP Gettingstarted Builtwithgo-app Contributors CodeContributors FinancialContributors Individuals Organizations README.md Go-appisapackageforbuildingprogressivewebapps(PWA)withtheGoprogramminglanguage(Golang)andWebAssembly(Wasm). ShapingaUIisdonebyusingadeclarativesyntaxthatcreatesandcomposeHTMLelementsonlybyusingtheGoprograminglanguage. ItusesGoHTTPstandardmodel. Anappcreatedwithgo-appcanoutoftheboxruninitsownwindow,supportsofflinemode,andareSEOfriendly. Documentation(builtwithgo-app) Install go-apprequirements: Go1.17ornewer Gomodule gomodinit goget-ugithub.com/maxence-charriere/go-app/v9/pkg/app Declarativesyntax Go-appusesadeclarativesyntaxsoyoucanwritereusablecomponent-basedUIelementsjustbyusingtheGoprogramminglanguage. HereisaHelloWorldcomponentthattakesaninputanddisplaysitsvalueinitstitle: typehellostruct{ app.Compo namestring } func(h*hello)Render()app.UI{ returnapp.Div().Body( app.H1().Body( app.Text("Hello,"), app.If(h.name!="", app.Text(h.name), ).Else( app.Text("World!"), ), ), app.P().Body( app.Input(). Type("text"). Value(h.name). Placeholder("Whatisyourname?"). AutoFocus(true). OnChange(h.ValueTo(&h.name)), ), ) } StandardHTTP Appscreatedwithgo-appcomplieswithGostandardHTTPpackageinterfaces. funcmain(){ //Componentsrouting: app.Route("/",&hello{}) app.Route("/hello",&hello{}) app.RunWhenOnBrowser() //HTTProuting: http.Handle("/",&app.Handler{ Name:"Hello", Description:"AnHelloWorld!example", }) iferr:=http.ListenAndServe(":8000",nil);err!=nil{ log.Fatal(err) } } Gettingstarted ReadtheGettingStarteddocument. Builtwithgo-app Lofimusic.app Murlok.io liwasc go-appDocs Contributors CodeContributors Thisprojectexiststhankstoallthepeoplewhocontribute.[Contribute]. FinancialContributors Becomeafinancialcontributorandhelpussustaingo-appdevelopment.[Contribute] Individuals Organizations Supportthisprojectwithyourorganization.Yourlogowillshowupherewithalinktoyourwebsite.[Contribute] About ApackagetobuildprogressivewebappswithGoprogramminglanguageandWebAssembly. go-app.dev Topics go golang gui ui pwa wasm awesome-go Resources Readme License MITLicense Codeofconduct Codeofconduct Releases 77 v9.2.1 Latest Nov8,2021 +76releases Sponsorthisproject   opencollective.com/go-app LearnmoreaboutGitHubSponsors Packages0 Nopackagespublished Usedby3 @kdevb0x/or-maybe-more @ericsgagnon/go-kube-learning @xiangdong1987/easyGin Contributors19 +8contributors Languages Go 97.9% JavaScript 1.2% Other 0.9% Youcan’tperformthatactionatthistime. Yousignedinwithanothertaborwindow.Reloadtorefreshyoursession. Yousignedoutinanothertaborwindow.Reloadtorefreshyoursession.



請為這篇文章評分?