From 314999ab6b2634456473dc8c1d55f761bcb087f9 Mon Sep 17 00:00:00 2001 From: Vlastimil Zeman Date: Wed, 26 Jan 2022 09:29:13 +0000 Subject: [PATCH] Add rationale to README --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8f40499..0c2dd20 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,9 @@ [![test_and_lint](https://github.com/sivchari/containedctx/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/sivchari/containedctx/actions/workflows/ci.yml) -containedctx is a linter that detects struct contained context.Context field +containedctx is a linter that detects struct contained context.Context field. +This is discouraged technique in favour of passing context as first argument of method or function. +For rationale please read [Contexts and structs](https://go.dev/blog/context-and-structs) the Go blog post. ## Instruction