Skip to content

Commit 0bfa73e

Browse files
committed
Updated the README.md file by adding a paragraph that provides further clarification on the purpose of the 'internal' directory.
1 parent 2d1e32a commit 0bfa73e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Private application and library code. This is the code you don't want others imp
6868

6969
You can optionally add a bit of extra structure to your internal packages to separate your shared and non-shared internal code. It's not required (especially for smaller projects), but it's nice to have visual clues showing the intended package use. Your actual application code can go in the `/internal/app` directory (e.g., `/internal/app/myapp`) and the code shared by those apps in the `/internal/pkg` directory (e.g., `/internal/pkg/myprivlib`).
7070

71-
You use internal directories to make packages private. If you put a package inside an internal directory, then other packages can’t import it unless they share a common ancestor. It’s the only directory named in Go’s documentation and has special compiler treatment.
71+
You use internal directories to make packages private. If you put a package inside an internal directory, then other packages can’t import it unless they share a common ancestor. And it’s the only directory named in Go’s documentation and has special compiler treatment.
7272

7373
### `/pkg`
7474

0 commit comments

Comments
 (0)