Skip to content

Commit 8b60e9d

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 87e7a48 commit 8b60e9d

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# examples
2+
23
Example on how to use Strawberry

django-subscriptions-rxdb/README.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
# django-subscriptions-rxdb
22

33
## tl;dr
4+
45
This example reproduces the server-side component of the RxDB GraphQL example, with a couple of extras, which can be found [here](https://github.com/pubkey/rxdb/tree/master/examples/graphql). Checkout RxDB and run the GraphQL example. When running Ok, change `export const GRAPHQL_PORT = 10102;` and `export const GRAPHQL_SUBSCRIPTION_PORT = 10103;` ([lines 1 and 3 of this file](https://github.com/pubkey/rxdb/blob/master/examples/graphql/shared.js)) to equal `8000`. Then in the directory of this README file, `make install && make run`. More information about RxDB and GraphQL synchronisation can be found [here](https://rxdb.info/replication-graphql.html).
56

67
## Requirements
8+
79
- [Clone of RxDB](https://github.com/pubkey/rxdb)
810
- [Python 3.8+](https://www.python.org/downloads/) (might work with other versions, not tested)
911
- [Poetry](https://python-poetry.org/)
@@ -13,7 +15,8 @@ This example reproduces the server-side component of the RxDB GraphQL example, w
1315
Tested on Ubuntu 20.04, should work everywhere these are available with no changes.
1416

1517
## Reason for this example
16-
While connectivity is getting better around the world every year, every user will always have moments when their connection is spotty (eg. on a plane). With an offline-first, local database and other offline-first tech (service workers, etc.), it is possible to develop web-technology-based applications that will continue to offer much of their functionality offline, with realtime sync when they are online. This really is the best of both worlds, and can give much more fluid and friendly usage when connections are spotty.
18+
19+
While connectivity is getting better around the world every year, every user will always have moments when their connection is spotty (eg. on a plane). With an offline-first, local database and other offline-first tech (service workers, etc.), it is possible to develop web-technology-based applications that will continue to offer much of their functionality offline, with realtime sync when they are online. This really is the best of both worlds, and can give much more fluid and friendly usage when connections are spotty.
1720

1821
So you already have a Django-based app, and want to add some rich, client-side, offline-first functionality without starting from scratch? This is an example of some of the server-side code for one way of starting out.
1922

0 commit comments

Comments
 (0)