浏览 209
分享
Import Aliasing
Import aliasing must be used if the package name does not match the lastelement of the import path.
- import (
- "net/http"
- client "example.com/client-go"
- trace "example.com/trace/v2"
- )
In all other scenarios, import aliases should be avoided unless there is adirect conflict between imports.
Bad | Good |
---|---|
|
|
评论列表