A collaborative note taking, wiki and documentation platform that scales. Built with Django and React.
Find a file
Charles Englebert 0fca6db79c
Integrate Find (#1834)
## Purpose

integrate Find to Docs

## Proposal

- [x]  add a `useSeachDocs` hook in charged of calling the search
endpoint.
- [x]  add a optional `path` param to the `search` route. This param
represents the parent document path in case of a sub-documents
(descendants) search.
- [x] ️return Indexer results directly without DB calls to retrieve the
Document objects. All informations necessary for display are indexed in
Find. We can skip the DB calls and improve performance.
- [x] ♻️ refactor react `DocSearchContent` components.
`DocSearchContent` and `DocSearchSubContent` are now merged a unique
component handling all search scenarios and relying on the unique
`search` route.
- [x] 🔥remove pagination logic in the Indexer. Removing the DB calls
also removes the DRF queryset object which handles the pagination. Also
we consider pagination not to be necessary for search v1.
- [x] 🔥remove the `document/<document_id>/descendants` route. This route
is not used anymore. The logic of finding the descendants are moved to
the internal `_list_descendants` method. This method is based on the
parent `path` instead of the parent `id` which has some consequence
about the user access management. Relying on the path prevents the use
of the `self.get_object()` method which used to handle the user access
logic.
- [x] handle fallback logic on DRF based title search in case of
non-configured, badly configured or failing at run time indexer.
- [x] handle language extension in `title` field. Find returns titles
with a language extension (ex: `{ title.fr: "rapport d'activité" }`
instead of `{ "title": "rapport d'activité" }`.
- [x] 🔧 add a `common.test` file to allow running the tests without
docker
- [x] ♻️ rename `SearchIndexer` -> `FindDocumentIndexer`. This class has
to do with Find in particular and the convention is more coherent with
`BaseDocumentIndexer`
- [x] ♻️ rename `SEARCH_INDEXER_URL` -> `INDEXING_URL` and
`SEARCH_INDEXER_QUERY_URL` -> `SEARCH_URL`. I found the original names
very confusing.
- [x] 🔧 update the environment variables to activate the
FindDocumentIndexer.
- [x] automate the generation of encryption key during bootstrap.
OIDC_STORE_REFRESH_TOKEN_KEY is a mandatory secret key. We can not push
it on Github and we want any contributor to be able to run the app by
only running the `make bootstrap`. We chose to generate and wright it
into the `common.local` during bootstrap.

## External contributions

Thank you for your contribution! 🎉  

Please ensure the following items are checked before submitting your
pull request:
- [x] I have read and followed the [contributing
guidelines](https://github.com/suitenumerique/docs/blob/main/CONTRIBUTING.md)
- [x] I have read and agreed to the [Code of
Conduct](https://github.com/suitenumerique/docs/blob/main/CODE_OF_CONDUCT.md)
- [x] I have signed off my commits with `git commit --signoff` (DCO
compliance)
- [x] I have signed my commits with my SSH or GPG key (`git commit -S`)
- [x] My commit messages follow the required format: `<gitmoji>(type)
title description`
- [x] I have added a changelog entry under `## [Unreleased]` section (if
noticeable change)
- [x] I have added corresponding tests for new features or bug fixes (if
applicable)

---------

Signed-off-by: charles <charles.englebert@protonmail.com>
2026-03-17 17:32:03 +01:00
.github 🔧(backend) add DB_PSYCOPG_POOL_ENABLED settings 2026-03-17 13:19:17 +01:00
bin Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
crowdin 🌐(action) upload sources translation on crowdin 2025-01-24 12:22:48 +01:00
docker 🩹(demo) update the email in realm.json 2025-09-16 17:23:26 +02:00
docs Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
env.d Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
gitlint 🚨(gitlint) Allow uppercase in commit messages 2025-03-18 10:24:08 +01:00
src Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
.dockerignore 🙈(docker) add .next to .dockerignore 2025-06-11 08:29:28 +02:00
.gitattributes 🔧(git) set LF line endings for all text files 2025-06-11 13:08:33 +02:00
.gitignore 🔧(compose) Add some ignore for docker-compose local overrides 2025-12-16 21:48:23 +01:00
.gitlint (project) first proof of concept printing pdf from markdown 2024-01-09 15:30:36 +01:00
.gitmodules 💚(ci) fix jobs after migration 2025-01-06 12:17:40 +01:00
.sops.yaml 🔐(secret) add spaccoud age key 2024-08-09 13:12:13 +02:00
CHANGELOG.md Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
CODE_OF_CONDUCT.md 📝(documentation) add banner to readme (#970) 2025-05-16 11:10:05 +02:00
compose-e2e.yml 🔧(project) change env.d system by using local files 2025-07-21 15:44:52 +02:00
compose.yml (docker) add docspec deployment and service to kubernetes configuration 2026-01-21 10:27:58 +01:00
CONTRIBUTING.md 📝 Fix documentation and comment typos (#1977) 2026-03-11 09:29:57 +00:00
Dockerfile 🔥(backend) remove rust from the back-builder Dockerfile stage 2026-03-05 21:38:05 +01:00
LICENSE (project) first proof of concept printing pdf from markdown 2024-01-09 15:30:36 +01:00
Makefile Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
publiccode.yml 📝(doc) add publiccode.yml (#770) 2025-03-19 21:28:32 +01:00
README.md Integrate Find (#1834) 2026-03-17 17:32:03 +01:00
renovate.json ⬇️(backend) downgrade django-treebeard to version < 5.0.0 2026-03-17 13:17:05 +01:00
secu-audit.md 📝(documentation) add banner to readme (#970) 2025-05-16 11:10:05 +02:00
SECURITY.md ✏️(project) automatic typo correction 2025-05-13 16:00:43 +02:00
UPGRADE.md 📝 Fix documentation and comment typos (#1977) 2026-03-11 09:29:57 +00:00

Docs

PRs Welcome MIT License

Chat on MatrixDocumentationTry DocsContact us

La Suite Docs: Collaborative Text Editing

Docs, where your notes can become knowledge through live collaboration.

Docs is an open-source collaborative editor that helps teams write, organize, and share knowledge together - in real time.

Live collaboration demo

What is Docs?

Docs is an open-source alternative to tools like Notion or Google Docs, focused on:

  • Real-time collaboration
  • Clean, structured documents
  • Knowledge organization
  • Data ownership & self-hosting

Built for public organizations, companies, and open communities.

Why use Docs?

Writing

  • Rich-text & Markdown editing
  • Slash commands & block system
  • Beautiful formatting
  • Offline editing
  • Optional AI writing helpers (rewrite, summarize, translate, fix typos)

Collaboration

  • Live cursors & presence
  • Comments & sharing
  • Granular access control

Knowledge management

  • Subpages & hierarchy
  • Searchable content

Export/Import & interoperability

  • Import to .docx and .md
  • Export to .docx, .odt, .pdf

Try Docs

Experience Docs instantly - no installation required.

Self-hosting

Docs supports Kubernetes, Docker Compose, and community-provided methods such as Nix and YunoHost.

Get started with self-hosting: Installation guide

Warning

Some advanced features (for example: Export as PDF) rely on XL packages from Blocknote. These packages are licensed under GPL and are not MIT-compatible

You can run Docs without these packages by building with:

PUBLISH_AS_MIT=true

This builds an image of Docs without non-MIT features.

More details can be found in environment variables

Local Development (for contributors)

Run Docs locally for development and testing.

Warning

This setup is intended for development and testing only. It uses Minio as an S3-compatible storage backend, but any S3-compatible service can be used.

Prerequisites

  • Docker
  • Docker Compose
  • GNU Make

Verify installation:

docker -v
docker compose version

If you encounter permission errors, you may need to use sudo, or add your user to the docker group.

Bootstrap the project

The easiest way to start is using GNU Make:

make bootstrap FLUSH_ARGS='--no-input'

This builds the app-dev and frontend-dev containers, installs dependencies, runs database migrations, and compiles translations.

It is recommended to run this command after pulling new code.

Start services:

make run

Open https://localhost:3000

Default credentials (development only):

username: impress
password: impress

Frontend development mode

For frontend work, running outside Docker is often more convenient:

make frontend-development-install
make run-frontend-development

Backend only

Starting all services except the frontend container:

make run-backend

Tests & Linting

make frontend-test
make frontend-lint

Backend tests can be run without docker. This is useful to configure PyCharm or VSCode to do it. Removing docker for testing requires to overwrite some URL and port values that are different in and out of Docker. env.d/development/common contains all variables, some of them having to be overwritten by those in env.d/development/common.test.

Demo content

Create a basic demo site:

make demo

More Make targets

To check all available Make rules:

make help

Django admin

Create a superuser:

make superuser

Admin UI: http://localhost:8071/admin

Contributing

This project is community-driven and PRs are welcome.

Roadmap

Curious where Docs is headed?

Explore upcoming features, priorities and long-term direction on our public roadmap.

License 📝

This work is released under the MIT License (see LICENSE).

While Docs is a public-driven initiative, our license choice is an invitation for private sector actors to use, sell and contribute to the project.

Credits ❤️

Stack

Docs is built on top of Django Rest Framework, Next.js, ProseMirror, BlockNote.js, HocusPocus, and Yjs. We thank the contributors of all these projects for their awesome work!

We are proud sponsors of BlockNotejs and Yjs.


Gov ❤️ open source

Docs is the result of a joint initiative led by the French 🇫🇷 (DINUM) Government and German 🇩🇪 government (ZenDiS).

We are always looking for new public partners (we are currently onboarding the Netherlands 🇳🇱), feel free to contact us if you are interested in using or contributing to Docs.

Europe Opensource