docs: fix links in getting started section + few other (#1026)

This commit is contained in:
Juro Oravec 2025-03-17 08:55:42 +01:00 committed by GitHub
parent 12a64f8e41
commit 8e7acd82be
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 83 additions and 70 deletions

View file

@ -1,8 +1,21 @@
### Reload dev server on component file changes
## Reload dev server on component file changes
This is relevant if you are using the project structure as shown in our examples, where
HTML, JS, CSS and Python are in separate files and nested in a directory.
```
sampleproject/
├── components/
│ └── calendar/
│ ├── calendar.py
│ └── calendar.html
│ └── calendar.css
│ └── calendar.js
├── sampleproject/
├── manage.py
└── requirements.txt
```
In this case you may notice that when you are running a development server,
the server sometimes does not reload when you change component files.
@ -12,10 +25,10 @@ From relevant [StackOverflow thread](https://stackoverflow.com/a/76722393/978863
> or in a nested sub directory of a templates directory. This is by design.
To make the dev server reload on all component files, set
[`reload_on_file_change`](#reload_on_file_change---reload-dev-server-on-component-file-changes)
[`reload_on_file_change`](../../../reference/settings#django_components.app_settings.ComponentsSettings.reload_on_file_change)
to `True`.
This configures Django to watch for component files too.
!!! note
!!! warning
This setting should be enabled only for the dev environment!