Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
benzkji committed Jan 23, 2024
1 parent 2835dc0 commit 4e68c2f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ Describe, index, search.

Default value, simplest possible configuration:

```
```python
POSTGRES_SEARCHINDEX = {
"default": {},
}
```

Example for a multilanguage setup:

```
```python
POSTGRES_SEARCHINDEX = {
"de": {
"kwargs": {
Expand All @@ -58,7 +58,7 @@ in searchindex key and kwargs.

Example, hopefully self explaining.

```
```python
from django.utils.html import strip_tags
from postgres_searchindex.base import IndexSource / MultiLanguageIndexSource
from postgres_searchindex.source_pool import source_pool
Expand All @@ -85,7 +85,7 @@ Place this code in `index_sources.py` of your app, and it will be autodiscovered

Run `./manage.py postgres_searchindex_update` to update/build the index.

```
```shell
» ./manage.py postgres_searchindex_update
====================================
Updating index "de" with kwargs {'language': 'de'}
Expand Down Expand Up @@ -113,7 +113,7 @@ your `IndexEntry` instances in Django admin.
You can now search in your index. You are free to use [Django's builtin fulltext](https://docs.djangoproject.com/en/dev/ref/contrib/postgres/search/)
features as you like - as in the following example, or in a way more advanced manner.

```
```python
from django.contrib.postgres.search import SearchVector
from postgres_searchindex.models import IndexEntry

Expand Down

0 comments on commit 4e68c2f

Please sign in to comment.