Skip to content

Commit 36166df

Browse files
committed
chore: more upgrade docs
1 parent 0d6a3e3 commit 36166df

File tree

2 files changed

+9
-6
lines changed

2 files changed

+9
-6
lines changed

docs/extend/routes.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,10 +143,6 @@ class HelloWorldController implements RequestHandlerInterface
143143
}
144144
```
145145

146-
### API Controllers
147-
148-
The `Flarum\Api\Controller` namespace contains a number of abstract controller classes that you can extend to easily implement new JSON-API resources. See [Working with Data](api.md) for more information.
149-
150146
## Frontend Routes
151147

152148
Adding routes to the frontend actually requires you to register them on _both_ the frontend and the backend. This is because when your route is visited, the backend needs to know to serve up the frontend, and the frontend needs to know what to display on the page.

docs/extend/update-2_0.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,16 @@ Familiarize yourself with the new [Code Splitting](./code-splitting) feature to
6161

6262
:::
6363

64-
### Admin Search
64+
### Forum Search
6565

6666
##### <span class="breaking">Breaking</span>
67-
* `app.extensionData` has been renamed to `app.registry`, but you should now use the [`Admin` extender](./admin.md) instead.
67+
* The forum search UI has been refactored to use a new `SearchModal` component.
68+
* The `flarum/forum/components/Search` component is no longer the global search component, it can still be used for custom search purposes.
69+
* Custom global search sources should be registered in `flarum/forum/components/GlobalSearch` `sourceItems` method.
70+
* Custom global search sources should now implement the `GlobalSearchSource` interface instead of `SearchSource`, see https://github.com/flarum/framework/blob/2.x/framework/core/js/src/common/components/AbstractSearch.tsx#L26-L69.
71+
* The `flarum/forum/states/SearchState` class has been moved to `flarum/common/states/SearchState`.
72+
73+
### Admin Search
6874

6975
##### <span class="notable">Notable</span>
7076
* The admin dashboard now has a search feature, as long as you register your settings/permissions using the `Admin` extender, then they will be automatically picked up.
@@ -97,6 +103,7 @@ Familiarize yourself with the new [Code Splitting](./code-splitting) feature to
97103
There have been many changes to the core frontend codebase, including renamed or moved methods/components, new methods/components, and more. It might help to look directly at the [JavaScript diffs](https://github.com/flarum/framework/issues?q=is%3Amerged+label%3Ajavascript+milestone%3A2.0+) to see what has changed. But here are some notable changes.
98104

99105
##### <span class="breaking">Breaking</span>
106+
* `app.extensionData` has been renamed to `app.registry`, but you should now use the [`Admin` extender](./admin.md) instead.
100107
* Some extension initializers [have been renamed to be more uniform](https://github.com/flarum/framework/pull/4003/files), if you are checking for initializer existence with `app.initializers.has('...')` you should update the name accordingly.
101108
* `IndexPage.prototype.sidebar` has been removed, use the `IndexSidebar` component instead.
102109
* `IndexPage.prototype.navItems` has been moved to `IndexSidebar.prototype.navItems`.

0 commit comments

Comments
 (0)