https://github.com/samwillis/electric-to-do
https://github.com/samwillis/electric-to-do
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/samwillis/electric-to-do
- Owner: samwillis
- Created: 2023-08-14T12:12:52.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-08-14T13:49:28.000Z (almost 3 years ago)
- Last Synced: 2025-03-29T08:34:02.379Z (about 1 year ago)
- Language: TypeScript
- Size: 223 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# An Example ElectricSQL app using React & the Ionic Framework
https://github.com/samwillis/electric-to-do/assets/31130/27ed3e26-c675-4e6c-bc49-5491b43613ce
Requirements:
- [Docker](https://www.docker.com)
- [Iconic CLI](https://ionicframework.com/docs/intro/cli)
Start the backend:
```shell
npm run backend:start
```
Open a new tab in your terminal. Navigate back to the same folder. Apply the migrations (defined in `./db/migrations`):
```shell
npm run db:migrate
```
Start your app:
```sh
ionic serve
```
## Notes
- `npm run backend:start` uses Docker Compose to start Postgres and the [Electric sync service](https://electric-sql.com/docs/api/service). See [running the examples](https://electric-sql.com/docs/examples/notes/running#running-your-own-postgres) for information about configuring the Electric sync service to run against an existing Postgres database.
- `npm run client:watch` calls `npx electric-sql generate --watch` under the hood. See [https://electric-sql.com/docs/api/generator](https://electric-sql.com/docs/api/generator) for more details.
## More information
- [Electric Documentation](https://electric-sql.com/docs)
- [Ionic Documentation](https://ionicframework.com/docs/react)