Skip to content

Commit a9e443d

Browse files
Updated part note (#5932)
Fixes #2371 --------- Co-authored-by: Marya <111139605+MaryaBelanger@users.noreply.github.com>
1 parent 3e42082 commit a9e443d

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

src/content/guides/libraries/create-packages.md

+5-8
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ to share software such as libraries and tools.
88
This page tells you how to create a standard shared
99
[package](/tools/pub/glossary#package).
1010

11-
1211
## Creating a new package
1312

1413
To create the initial directory and structure for a package,
@@ -19,10 +18,6 @@ and the `package` template:
1918
$ dart create -t package <PACKAGE_NAME>
2019
```
2120

22-
{% comment %}
23-
TODO: Add coverage of packages that contain tools.
24-
{% endcomment %}
25-
2621
## What makes a package
2722

2823
The following diagram shows the simplest layout of a package:
@@ -59,9 +54,11 @@ In most cases, each class should be in its own mini library, unless
5954
you have a situation where two classes are tightly coupled.
6055

6156
:::note
62-
You may have heard of the `part` directive, which allows
63-
you to split a library into multiple Dart files. We recommend
64-
that you avoid using `part` and create mini libraries instead.
57+
You might know about the `part` directive.
58+
This directive allows you to split a library into multiple Dart files.
59+
Though part files can incorporate generated code into a library,
60+
the Dart team doesn't recommend using them.
61+
Instead, create small libraries.
6562
:::
6663

6764
Create a "main" library file directly under lib,

0 commit comments

Comments
 (0)