You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pages/Namespaces.md
+22-1Lines changed: 22 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,4 +2,25 @@ type:: [[Feature]]
2
2
platforms:: [[All Platforms]]
3
3
description:: Used to group a set of related pages
4
4
5
-
- TODO Document this feature. Close https://github.com/logseq/docs/issues/58 when done #docs
5
+
-
6
+
- Namespaces can be used to **avoid name conflicts** and **build hierarchical page relationships**.
7
+
- A page can be placed in a namespace by putting the namespace and a slash in the page's title.
8
+
- For example, to put this page in the `Important Features` namespace, you would title it `Important Features/Namespaces`
9
+
-
10
+
- Namespaces can be stacked: `Important Features/Very Important Features/Namespaces`
11
+
- Pages in a namespace are automatically backlinked to the namespace's page.
12
+
- In our above example where we name this page `Important Features/Namespaces`, the page would be automatically backlinked to `Important Features`, and show up in the linked references section at the bottom.
13
+
- In the above multilevel namespace example, `Namespaces` would be backlinked to `Very Important Features`, and `Very Important Features` would be backlinked to `Important Features`.
14
+
-
15
+
-## Example: Hierarchical Relationships
16
+
- Suppose you have a `[[Recipes]]` page, but you have so many recipes that it's inconvenient to put them all on a single page.
17
+
- You might still want to index all of them on one page. While doing so manually is possible, if you create a new page and forget to link it, it could be hard to find later.
18
+
- Instead, putting them in the `Recipes` namespace will automatically backlink them to the `Recipes` page, so that you never lose them. Naming your pages like `Recipes/Pho` and `Recipes/Chicken Noodle Soup` will backlink both of these to `Recipes.`
19
+
- If you wish to further organize your notes, this backlinking occurs at every namespace level.
20
+
- Suppose you wanted to sort your recipes by category, and put pho and chicken noodle soup in the soup category.
21
+
- You could title them `Recipes/Soup/Pho` and `Recipes/Soup/Chicken Noodle Soup`. Then, `Pho` and `Chicken Noodle Soup` would be backlinked to `Soup`, and `Soup` would be backlinked to `Recipes`.
22
+
-
23
+
-## Example: Avoiding Name Conflicts
24
+
- Logseq will not let you name two pages the exact same thing.
25
+
- If you want two pages with the same name, they must be in different namespaces to prevent a conflict.
26
+
- For example, suppose you want to keep separate notes on airbrushing for model painting and airbrushing for baking. You could name them `Model Painting/Airbrushing` and `Baking/Airbrushing` to make them distinguishable.
0 commit comments