{"id":18781068,"url":"https://github.com/dacurse/note-app","last_synced_at":"2025-12-19T05:30:16.373Z","repository":{"id":45350530,"uuid":"434934691","full_name":"DaCurse/note-app","owner":"DaCurse","description":"An API for a note taking app.","archived":false,"fork":false,"pushed_at":"2021-12-18T22:48:17.000Z","size":88,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-29T11:13:58.424Z","etag":null,"topics":["crud","express","javascript","nodejs","prisma"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DaCurse.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-12-04T15:14:57.000Z","updated_at":"2023-03-08T21:33:55.000Z","dependencies_parsed_at":"2022-08-29T22:11:31.543Z","dependency_job_id":null,"html_url":"https://github.com/DaCurse/note-app","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaCurse%2Fnote-app","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaCurse%2Fnote-app/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaCurse%2Fnote-app/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaCurse%2Fnote-app/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DaCurse","download_url":"https://codeload.github.com/DaCurse/note-app/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239698853,"owners_count":19682534,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crud","express","javascript","nodejs","prisma"],"created_at":"2024-11-07T20:29:29.459Z","updated_at":"2025-12-19T05:30:16.314Z","avatar_url":"https://github.com/DaCurse.png","language":"JavaScript","readme":"# note-app\n\nAn API for a note taking app.\n\nI made this little project because I find writing pure express apps, without any sophisticated frameworks (Like [Nest.js](https://nestjs.com/)) fun, and also because I wanted to create a project structure I am happy with, and I think I got close here.\n\nThis project structure seperates responsibilities to different components (Routes, services, etc.), and has nifty utilities like clean declarative validation which automatically throws descriptive errors:\n\n```js\nrouter.get('/', validate(getNotesSchema, 'query'), async (req, res) =\u003e\n  res.json(await getNotes(req.query.limit))\n);\n```\n\nIf `req.query` doesn't match the schema, I get an error:\n\n```json\n{\n  \"status\": 400,\n  \"message\": \"\\\"id\\\" must be a number\"\n}\n```\n\n## Running the project\n\nRename [.env.example](./.env.example) to `.env` and fill in the required information.\n\nInstall dependencies using your preferred package manager (I use [pnpm](https://pnpm.io/)):\n\n```sh\npnpm i\n```\n\nRun in watch mode (for development):\n\n```sh\npnpm start:dev\n```\n\nOr for production:\n\n```sh\nDEBUG=note-app:* pnpm start\n```\n\n_The `DEBUG` environment variable doesn't work with `.env` files._\n\n### With Docker\n\nBuild an image from the repo:\n\n```sh\nsudo docker image build https://github.com/DaCurse/note-app.git -t note-app:latest\n```\n\nAnd create a container:\n```sh\ndocker run -d \\\n  -it \\\n  --restart unless-stopped \\\n  --name note-app -p 80:80 \\\n  -e \"DATABASE_URL=\u003cpostgres connection string\u003e\" \\\n  --mount type=bind,source=/var/lib/note-app/data,target=/var/lib/postgresql/data/pgdata \\\n  note-app:latest\n```\n\n### With docker-compose\n\nWith `docker-compose`, a `postgres` server is started alongisde the app.\n\nClone the repo:\n\n```sh\ngit clone https://github.com/DaCurse/note-app.git\ncd note-app\n```\n\nStart the app:\n\n```sh\nsudo docker-compose up -d\n```\n\n## License\n\nSee [LICENSE](./LICENSE).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdacurse%2Fnote-app","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdacurse%2Fnote-app","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdacurse%2Fnote-app/lists"}