-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
66 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,76 @@ | ||
# React + TypeScript + Vite | ||
# Sat Parity Tracker | ||
|
||
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules. | ||
A real-time Bitcoin purchasing power tracker that monitors when different currencies reach "sat parity" - the point where 1 satoshi equals or exceeds 1 unit of that currency. | ||
|
||
Currently, two official plugins are available: | ||
## Features | ||
|
||
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh | ||
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh | ||
- **Real-time Exchange Rates**: Tracks Bitcoin exchange rates against multiple currencies | ||
- **Parity Tracking**: Shows historical and predicted future parity dates for each currency | ||
- **Visual Status**: Color-coded cards indicating parity status: | ||
- Blue: Already reached parity | ||
- Gold: Just hit parity | ||
- Red: Expected parity within 1 year | ||
- Orange: Expected parity within 4 years | ||
- Green: Expected parity beyond 4 years | ||
- **Progress Tracker**: "The Sattening" progress bar showing the percentage of currencies that have reached sat parity | ||
- **Bitcoin Integration**: Support the project with Bitcoin donations via Alby wallet integration | ||
- **Responsive Design**: Works seamlessly across desktop and mobile devices | ||
|
||
## Expanding the ESLint configuration | ||
## Technical Stack | ||
|
||
If you are developing a production application, we recommend updating the configuration to enable type aware lint rules: | ||
- React 18 | ||
- TypeScript | ||
- Vite | ||
- Tailwind CSS | ||
- Alby Bitcoin Connect SDK | ||
|
||
- Configure the top-level `parserOptions` property like this: | ||
## Development | ||
|
||
```js | ||
export default tseslint.config({ | ||
languageOptions: { | ||
// other options... | ||
parserOptions: { | ||
project: ['./tsconfig.node.json', './tsconfig.app.json'], | ||
tsconfigRootDir: import.meta.dirname, | ||
}, | ||
}, | ||
}) | ||
### Prerequisites | ||
|
||
- Node.js | ||
- Yarn or npm | ||
|
||
### Setup | ||
|
||
1. Clone the repository: | ||
```bash | ||
git clone https://github.com/rolznz/satparity.git | ||
cd satparity | ||
``` | ||
|
||
2. Install dependencies: | ||
```bash | ||
yarn install | ||
``` | ||
|
||
3. Start the development server: | ||
```bash | ||
yarn dev | ||
``` | ||
|
||
The application will be available at `http://localhost:5173`. | ||
|
||
### Building for Production | ||
|
||
```bash | ||
yarn build | ||
``` | ||
|
||
- Replace `tseslint.configs.recommended` to `tseslint.configs.recommendedTypeChecked` or `tseslint.configs.strictTypeChecked` | ||
- Optionally add `...tseslint.configs.stylisticTypeChecked` | ||
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and update the config: | ||
|
||
```js | ||
// eslint.config.js | ||
import react from 'eslint-plugin-react' | ||
|
||
export default tseslint.config({ | ||
// Set the react version | ||
settings: { react: { version: '18.3' } }, | ||
plugins: { | ||
// Add the react plugin | ||
react, | ||
}, | ||
rules: { | ||
// other rules... | ||
// Enable its recommended rules | ||
...react.configs.recommended.rules, | ||
...react.configs['jsx-runtime'].rules, | ||
}, | ||
}) | ||
### Running Tests | ||
|
||
```bash | ||
yarn lint | ||
``` | ||
|
||
## Contributing | ||
|
||
Contributions are welcome! Please feel free to submit a Pull Request. | ||
|
||
## License | ||
|
||
MIT License. See LICENSE file for details. | ||
|
||
## Acknowledgments | ||
|
||
Built with PPQ.ai using the Cline VSCode plugin with Claude 3.5 Sonnet. |