log / tags / go

9 posts tagged with "go"

setup go debugger using delve and air

Guide on using delve as a debugger for Go programming. Configure air for hot reloading and set up debugging in VSCode and Neovim.

22 Feb 2024 2 min read

setup go debugger using delve and air

Guide on using delve as a debugger for Go programming. Configure air for hot reloading and set up debugging in VSCode and Neovim.

22 Feb 2024 2 min read

setup air config for templ

Change some configurations in `.air.toml` to get air to work with templ, including adding templ generate, excluding templ generated files, and watching files with .templ extension.

21 Feb 2024 1 min read

setup air config for templ

Change some configurations in `.air.toml` to get air to work with templ, including adding templ generate, excluding templ generated files, and watching files with .templ extension.

21 Feb 2024 1 min read

setup static path in go fiber using embedded file system

Use the embedded file system in GoFiber to serve static files. This guide provides an example of how to replace the 'app.Static' with middleware 'app.Use'. Also, find out how to expose only the index.html.

11 Jan 2024 1 min read

check file system when using go embed

Learn how to check an embedded filesystem in Go by attempting to access a file or directory from it. This guide provides a step-by-step example using the ReadFile operation.

11 Jan 2024 1 min read

default env variable name in pgx

Discover the convenience of using pgx in Go to connect to a database without needing to pass username and password. The pgx function automatically checks default environment variables, streamlining the connection process.

31 Oct 2023 1 min read

rendering page layout in fiber

Render page layouts in Go Fiber using the ViewEngine. The guide showcases how to pass a layout during rendering, set a default layout to the engine, and exclude the layout when it's already set in the engine.

27 Oct 2023 1 min read

get route params in fiber

Understand the method to get route parameters in Go/Fiber. The snippet shows how to retrieve a parameter from the URL path using `c.Params("foo")` function.

25 Oct 2023 1 min read