Skip to content

Latest commit

 

History

History
37 lines (28 loc) · 452 Bytes

import-group.md

File metadata and controls

37 lines (28 loc) · 452 Bytes

Import Group Ordering

There should be two import groups:

  • Standard library
  • Everything else

This is the grouping applied by goimports by default.

BadGood
import (
  "fmt"
  "os"
  "go.uber.org/atomic"
  "golang.org/x/sync/errgroup"
)
import (
  "fmt"
  "os"

  "go.uber.org/atomic"
  "golang.org/x/sync/errgroup"
)