Receipt-collation software I'm building for fun for a use-case at my company where we have to collate receipts from a trip for claims later on.
Could be a start-up idea, idk.
- Solid
- Vike (I just like it better than Solid-Start because it feels like Svelte for me, also more customizable like making it pass
req
andres
into mypageContext
, separate files for+data.ts
,+config.ts
. It's a bit verbose in the beginning but it becomes quite pragmatic overtime.)) - Hono - thanks to Vike, I can run it on any web framework of my choosing.
- Turso + Drizzle ORM
- Backblaze - File Uploads (LocalStack for S3 in localhost)
- Lucia
- Docker Desktop
- Bun
- Clone
git clone https://github.com/blankeos/spend-snap.git
cd spend-snap
- LocalStack (S3) - For dev only
# Run localstack to check docker-compose.yml
bun s3:create
# AWS Configure first (Just use placeholders: https://github.com/localstack/localstack/issues/8424)
aws configure
> AWS Access Key ID [****************root]: root
> AWS Secret Access Key [****************password]: password
> Default region name [us-east-1]: us-east-1 # Because has the features we need.
> Default output format [None]:
# Create a bucket in s3.
aws --endpoint-url=http://localhost:9000 s3api create-bucket --bucket spend-snap --region us-east-1
# List buckets
aws --endpoint-url=http://localhost:9000 s3api list-buckets
# Alternatively, just visit http://localhost:9000 for the Web UI. Use the root(access key id) and password (access key) to login.
- Copy and fill env
cp .env.example .env
- Install deps and run
bun install
bun run dev
- Go to Application Keys create a new application key (for the specific project) and save it.
- Setup cors in Backblaze Bucket
brew install b2-tools
# Use your master key here
b2 account authorize
b2 bucket update --cors-rules '[
{
"corsRuleName": "downloadFromAnyOriginWithUpload",
"allowedOrigins": [
"*"
],
"allowedHeaders": [
"*"
],
"allowedOperations": [
"s3_put"
],
"maxAgeSeconds": 3600
}
]' bucketNameHere
Endpoint
has to be s3...com