Add "single tree mode" when building

This commit is contained in:
Przemek Więch
2023-08-28 23:08:19 +02:00
parent 4049b322e7
commit 508271593b
2 changed files with 44 additions and 7 deletions

View File

@@ -101,6 +101,21 @@ https://github.com/PeWu/topola-viewer/archive/refs/heads/gh-pages.zip
These are the exact files that are hosted on GitHub pages.
### Build for your own data only
You can run Topola Viewer in a "single tree mode" that displays only the GEDCOM you specify. Specify the URL to a GEDCOM file in the `REACT_APP_STATIC_URL` environment variable when building and running the application.
Run locally with the specified data URL:
```
REACT_APP_STATIC_URL=https://example.org/sample.ged npm start
```
Build with the specified data URL:
```
REACT_APP_STATIC_URL=https://example.org/sample.ged npm run build
```
The `build/` folder will contain files that can be hosted on a Web server.
### Alternative build
The [topola-webpack](https://github.com/develancer/topola-webpack) tool can build a Topola Genealogy Viewer package bundled together with a GEDCOM file.