Skip to content

Instantly share code, notes, and snippets.

View obalunenko's full-sized avatar
:octocat:
Clear is better than clever

Oleg Balunenko obalunenko

:octocat:
Clear is better than clever
View GitHub Profile
@obalunenko
obalunenko / golang_templates_cheatsheet.md
Created May 4, 2022 07:57
Golang Templates Cheatsheet

Golang Templates Cheatsheet

Posted 14 Sep 2017

(saved from curtisvermeeren.github.io)

The Go standard library provides a set of packages to generate output. The text/template package implements templates for generating text output, while the html/template package implements templates for generating HTML output that is safe against certain attacks. Both packages use the same interface but the following examples of the core features are directed towards HTML applications.


@obalunenko
obalunenko / pprof.md
Created November 14, 2023 13:06 — forked from slok/pprof.md
Go pprof cheat sheet

Enable profiling

Default http server

import (
    _ "net/http/pprof"
    "net/http"
)