I am new to golang and want to use it for web application development . anyone here can give me resources to build a web app ? Basically i am making a shopping cart ! So please help
评论:
alioygur:
flippeeer:https://www.gitbook.com/book/astaxie/build-web-application-with-golang/details
shovelpost:
bakunin:
thewhitetulip:Great course for learning go: https://www.udemy.com/learn-how-to-code/
Good course for learning webdev with go: https://www.udemy.com/go-programming-language/
At it's core, a webapp takes an input (http request) and returns an http response.
When it gets the http request, it takes a look at the token sent by the browser, if it is present, it logs the user in, if not, then it redirects the user to login page.
if the user is authenticated, they are redirected to the home page '/'. '/' is the URL, we have a handler for each URL pattern.
The handlers talk to the database and populate the html templates (which are written in Go's templating syntax).
guide: https://github.com/thewhitetulip/web-dev-golang-anti-textbook/
REST API example of ecommerce: https://gitlab.com/thewhitetulip/shop-rest
