{"id":23629618,"url":"https://github.com/stevesuv/remix-words-funny","last_synced_at":"2025-05-15T08:07:17.567Z","repository":{"id":269783264,"uuid":"907342962","full_name":"SteveSuv/remix-words-funny","owner":"SteveSuv","description":"a fullstack English words study website: remix (react-router v7) + trpc + drizzle + postgresql + heroui + jotai + docker","archived":false,"fork":false,"pushed_at":"2025-04-22T16:14:30.000Z","size":2589,"stargazers_count":758,"open_issues_count":1,"forks_count":80,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-04-22T17:33:27.352Z","etag":null,"topics":["docker","drizzle-orm","heroui","jotai","jwt","lucide-icons","nodemailer","postgresql","react","react-query","react-router","remix","tailwindcss","trpc","typescript","vite"],"latest_commit_sha":null,"homepage":"https://wordsfunny.com","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SteveSuv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-23T11:19:02.000Z","updated_at":"2025-04-22T16:14:34.000Z","dependencies_parsed_at":"2025-03-18T00:41:37.030Z","dependency_job_id":"414acf96-0a8b-4109-ad02-26ac803155da","html_url":"https://github.com/SteveSuv/remix-words-funny","commit_stats":null,"previous_names":["stevesuv/remix-words-funny"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SteveSuv%2Fremix-words-funny","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SteveSuv%2Fremix-words-funny/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SteveSuv%2Fremix-words-funny/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SteveSuv%2Fremix-words-funny/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SteveSuv","download_url":"https://codeload.github.com/SteveSuv/remix-words-funny/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254301433,"owners_count":22047904,"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":["docker","drizzle-orm","heroui","jotai","jwt","lucide-icons","nodemailer","postgresql","react","react-query","react-router","remix","tailwindcss","trpc","typescript","vite"],"created_at":"2024-12-28T01:16:20.341Z","updated_at":"2025-05-15T08:07:17.504Z","avatar_url":"https://github.com/SteveSuv.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# remix-words-funny\n\nA fullstack English words study website built with [remix-t3-stack](https://github.com/SteveSuv/remix-t3-stack)\n\n![image](https://github.com/user-attachments/assets/6e57831f-9915-4f6f-9c2f-93040b0dcede)\n\n# features\n\n- end-to-end type safe by `trpc`\n- get `myUserInfo` anywhere by `useMyUserInfo`\n- type safe form with `zod` by `useZodForm`\n- no need to export `action` in routes, just call `trpcClient.action` to mutate anywhere\n- request with permission control by `trpc middlewares`\n- deploy by `docker` or `pm2`\n- support dark mode by `useAppTheme`\n- use `drizzle` to keep type safe with `postgresql` db\n- toast request error automatically\n- always use latest remix (react-router v7) features\n\n# stack\n\n- remix (react-router v7)\n- vite\n- trpc\n- tailwindcss\n- heroUI\n- typescript\n- drizzle\n- postgresql\n- jwt\n- jotai\n- pnpm\n- react-hook-form\n- react-query\n- next-themes\n- lucide-icons\n- zod\n- docker\n\n# how to dev\n\n1. clone this repository\n\n```\ngit clone git@github.com:SteveSuv/remix-words-funny.git\n```\n\n2. install packages\n\n```\nnpm i pnpm -g\npnpm i\n```\n\n3. init database\n\n- install [docker](https://www.docker.com/get-started/) and start docker service\n- first run command below to create a local postgres container (you can replace the `POSTGRES_PASSWORD_EXAMPLE`):\n\n```sh\ndocker run -d --name postgres -p 5432:5432 -v postgres_data:/var/lib/postgresql/data -e POSTGRES_USER=postgres -e POSTGRES_PASSWORD=POSTGRES_PASSWORD_EXAMPLE -e POSTGRES_DB=wordsfunny postgres:16-alpine\n```\n\n- run command `pnpm db:push` to sync db structs and drizzle schema\n- download csv data file: https://mypikpak.com/s/VOEs95bTB0KGAg75t0Nrs-oOo1\n- use your favorite db tool like [TablePlus](https://tableplus.com/) to connect the postgres db\n- insert db data by import csv files to tables. Notice! you should first import `Book`, then `Word`, then others, because tables have some relations\n- run `pnpm db:task`, if print `total words count: 152543` means the postgres db is running ok\n\n4. init email server (optional, if you don't want to send login verify code)\n\n- when you dev local, you can just print the verify code simply\n- when you deploy to prod, you can use some email server saas like [resend](https://resend.com/)\n- or you can enable some email server's SMTP, then add `EMAIL_SERVER_ADDRESS` and `EMAIL_SERVER_PASS` to .env file, like [Netease Email](https://mail.163.com/) or [QQ Email](https://mail.qq.com/)\n\n5. run dev server\n\n```\npnpm dev\n```\n\n6. build and preview\n\n```\npnpm build\npnpm start\n```\n\n# how to deploy\n\n- deploy by docker\n\n```\npnpm run deploy\n```\n\n- deploy by pm2\n\n```\n# push files to server\nrsync -avz build node_modules package.json .env root@HOST:~/remix-words-funny/\n\n# ssh server and run app\nssh root@HOST \"cd ~/remix-words-funny \u0026\u0026 pm2 start npm -- start\"\n```\n\n# notice\n\n- suggest node version greater than 22\n- when you dev local, you should run `docker stop wordsfunny-app` first to stop container to avoid port 3001 occupation\n- words resource [repo](https://github.com/kajweb/dict)\n- more features will be added gradually\n- a more simple `remix-t3-stack` project for beginners is here: [remix-t3-stack](https://github.com/SteveSuv/remix-t3-stack)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstevesuv%2Fremix-words-funny","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstevesuv%2Fremix-words-funny","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstevesuv%2Fremix-words-funny/lists"}