Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lucasmercado101/brief
Offline-first note taking app.
https://github.com/lucasmercado101/brief
bun elm elysiajs fullstack
Last synced: about 1 month ago
JSON representation
Offline-first note taking app.
- Host: GitHub
- URL: https://github.com/lucasmercado101/brief
- Owner: Lucasmercado101
- License: agpl-3.0
- Created: 2023-09-04T22:57:23.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-26T22:41:22.000Z (about 1 year ago)
- Last Synced: 2024-11-16T22:34:42.255Z (about 1 month ago)
- Topics: bun, elm, elysiajs, fullstack
- Language: Elm
- Homepage:
- Size: 1.03 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Brief - Capture Your Thoughts Effortlessly ๐
![](https://github.com/Lucasmercado101/Brief/blob/main/banner.png)
**Brief** is an intuitive, offline-first personal note-taking Progressive Web App (PWA) designed to help you capture and organize your thoughts, tasks, and ideas. It seamlessly syncs your notes across all your devices whenever you have an internet connection, ensuring you never miss a beat. Inspired by [Google Keep](https://keep.google.com/).
## Table of Contents ๐
- [Introduction](#introduction)
- [Features](#features)
- [Technologies Used](#technologies-used)
- [Getting Started](#getting-started)
ย - [Prerequisites](#prerequisites)
ย - [Setting Up the Project](#setting-up-the-project)
- [How It Works](#how-it-works)
- [Contributing](#contributing)
- [License](#license)
- [Acknowledgments](#acknowledgments)
## Introduction ๐
Welcome to **Brief** - a modern, offline-first note-taking app tailored for your personal and professional life. Our progressive web app (PWA) is all about helping you jot down and organize your ideas, tasks, and notes seamlessly. Whether you're offline or online, Brief ensures your notes are just a tap away, ready to be synced whenever you're connected to the internet. This open-source project embraces the AGPL-3.0 license, inviting a vibrant community of users and developers to use, enhance, and customize it for free.
## Features โจ
- **Offline Capabilities**: Take and manage notes anytime, anywhere.
- **Note Operations**: Add, edit, delete, and rearrange notes effortlessly.
- **Label Management**: Customize and manage labels for better organization.
- **Sync**: A smart command API pattern ensures your data remains up-to-date across all your devices.
- [ ] **Progressive Web App**: Enhancing the app to work as a Progressive Web App.
- [ ] **Database Syncing**: Future capabilities include syncing IndexedDB with the server for a seamless offline experience.
- [ ] **Real-time Editing**: Soon, you'll be able to collaborate with others in real-time with Operational Transactions.
## Technologies Used ๐ ๏ธ
- **Frontend**: Crafted using [Elm](https://elm-lang.org/), featuring Material Design icons.
- **Backend**: Powered by [ElysiaJS](https://elysiajs.com/), with a [Prisma.js](https://www.prisma.io/) ORM and PostgreSQL database.
- **Sync Strategy**: Utilizing an "Offline Queue" and "Last Write Wins" approach to resolve conflicts.
- **Session Management**: Utilizes signed cookie-based sessions to enhance security and maintain a reliable user experience.
## How It Works ๐
Brief implements a Command API pattern to intelligently manage your actionsโlike creating, updating, or deleting notes and labelsโby queuing them up until an internet connection is available. All local changes are securely stored and then synchronized with the server, which serves as the Single Source of Truth (SSOT). This ensures that your data is consistent across all devices and sessions once synced.
## Getting Started ๐
### Prerequisites
To set up your local environment for Brief, you will need:
- [Docker](https://www.docker.com/)
- [Bun](https://bun.sh/) (a JavaScript runtime)
- [Elm](https://elm-lang.org/)
### Setting Up the Project
1. Clone the repository:
```
git clone https://github.com/Lucasmercado101/Brief
```
2. **Start a Docker PostgreSQL instance**:
```
docker run --name notes-db -d -e POSTGRES_DB=mydb -e POSTGRES_PASSWORD=testpass123 -e POSTGRES_USER=postgres -p "6500:5432" postgres
```
3. **Access the Database with PSQL**:
```
psql -U postgres -d mydb
```
4. **Frontend Setup**:
```
npm install
npm run dev
```
ย Serve the HTML or use `elm reactor` and access the app at `http://localhost:8000/frontend/public/index.html`.
5. **Backend Setup**:
```
bun install
bun prisma generate
bun dev
```
6. **Environment Variables**:
Set up your `.env` file with the following entries:
```
DATABASE_URL="postgresql://postgres:testpass123@localhost:6500/mydb"
COOKIE_SECRETS="secret"
```
## License ๐
This project is licensed under the AGPL-3.0 License - see the [LICENSE](LICENSE) file for details.