Skip to content

Commit

Permalink
Merge pull request #569 from isaacdonaldson/documentation-change
Browse files Browse the repository at this point in the history
Added disclaimer for extractor ordering
  • Loading branch information
kaplanelad authored May 3, 2024
2 parents b92fbdf + f5f2287 commit dc85746
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion docs-site/content/docs/getting-started/guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ Make sure you also have locally installed or running (via Docker or otherwise) i
- Redis

<div class="infobox">
To configure a database , please run a local postgres database with <code>loco:loco</code> and a db named <code>myapp_development</code>.
To configure a database, please run a local postgres database with <code>loco:loco</code> and a db named <code>myapp_development</code>.
</div>

This docker command start up postgresql database server.
Expand Down Expand Up @@ -615,6 +615,12 @@ A few items to note:
- It's always better to create a `load_item` helper function and use it in all singular-item routes.
- While `use loco_rs::prelude::*` brings in anything you need to build a controller, you should note to import `crate::models::_entities::articles::{ActiveModel, Entity, Model}` as well as `Serialize, Deserialize` for params.
<div class="infobox">
The order of the extractors is important, as changing the order of them can lead to compilation errors. Adding the <code>#[debug_handler]</code> macro to handlers can help by printing out better error messages. More information about extractors can be found in the <a href="https://docs.rs/axum/latest/axum/extract/index.html#the-order-of-extractors">axum documentation</a>.
</div>
You can now test that it works, start the app:
```sh
Expand Down

0 comments on commit dc85746

Please sign in to comment.