📝 Update details syntax with new pymdown extensions format (#713)

This commit is contained in:
Sebastián Ramírez
2023-11-28 23:12:33 +01:00
committed by GitHub
parent be464fba69
commit 799d0aa7a6
37 changed files with 409 additions and 614 deletions

View File

@ -45,14 +45,13 @@ We will later update **Spider-Boy** to add him to the **Preventers** team too, b
We will continue with the code in the previous example and we will add more things to it.
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/create_tables/tutorial001.py!}
```
</details>
///
Make sure you remove the `database.db` file before running the examples to get the same results.
@ -72,14 +71,13 @@ Let's start by creating two teams:
# Code below omitted 👇
```
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/insert/tutorial001.py!}
```
</details>
///
This would hopefully look already familiar.
@ -103,14 +101,13 @@ Let's not forget to add this function `create_heroes()` to the `main()` function
# Code below omitted 👇
```
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/insert/tutorial001.py!}
```
</details>
///
## Run it
@ -151,14 +148,13 @@ As the `Hero` class model now has a field (column, attribute) `team_id`, we can
# Code below omitted 👇
```
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/insert/tutorial001.py!}
```
</details>
///
We haven't committed this hero to the database yet, but there are already a couple of things to pay **attention** to.
@ -190,14 +186,13 @@ Let's now create two more heroes:
# Code below omitted 👇
```
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/insert/tutorial001.py!}
```
</details>
///
When creating `hero_rusty_man`, we are accessing `team_preventers.id`, so that will also trigger a refresh of its data, generating an output of:
@ -236,14 +231,13 @@ Now let's refresh and print those new heroes to see their new ID pointing to the
# Code below omitted 👇
```
<details>
<summary>👀 Full file preview</summary>
/// details | 👀 Full file preview
```Python
{!./docs_src/tutorial/connect/insert/tutorial001.py!}
```
</details>
///
If we execute that in the command line, it will output: