MENU

Fun & Interesting

The standard library now has all you need for advanced routing in Go.

Dreams of Code 185,328 lượt xem 1 year ago
Video Not Working? Fix It Now

Use my link https://sponsr.is/tld_dreamsofcode and code APPDEVFOO5 and get a .dev, .app, or .foo domain name for only $5!

This video is sponsored by Porkbun.

Since 1.22, the Go standard library now has everything we need to perform advanced routing without the need of a third party dependency. However, knowing how to perform tasks such as middleware, path parameters, subrouting and more can be difficult to know. So, in this video, we look at how to do advanced routing features in Go.

Become a better developer in 4 minutes: https://bit.ly/45C7a29 👈

Code from project:
https://github.com/dreamsofcode-io/nethttp

Join this channel to get access to perks:
https://www.youtube.com/channel/UCWQaM7SpSECp9FELz-cHzuQ/join

Join my Discord: https://discord.com/invite/eMjRTvscyt
Follow me on Twitter: https://twitter.com/dreamsofcode_io

00:00:00 Intro
00:00:22 Path parameters
00:02:09 Method based routing
00:03:45 Host based routing + sponsor
00:06:07 Middleware
00:08:56 Middleware chaining
00:10:04 Subrouting
00:11:24 Context

Comment