└── README.md /README.md: -------------------------------------------------------------------------------- 1 | Some reasons why I'm tired of webdev. Please don't add your reasons, I have enough already. 2 | If you think there's a fix for something, please open a PR and tell me how. Thank you. 3 | 4 | ## WebStorm 5 | ### Imports 6 | Fuck auto imports in WebStorm, seriously. I want my editor to import things on the fly. I have the option "import on the fly" checked but it doesn't work. 7 | - Sometimes it imports things twice (super frustrating) 8 | - Auto-import {Box} from "ink" even though in 13948138413 files I import it from @mantine-ui/core 9 | - Not suggesting auto-imports for components like the Text component 10 | - If I'm using Vertical from the same library in 19384813 files, just import it from the same frickin library and don't ask me where to import it from!!! 11 | - When working with Blitz and Prisma 12 | - auto imports from "db" don't work at all 13 | - returns from resolvers show yellow squiggly lines (FML) 14 | - Importing an icon from react-icons gets imported from react-icons/all instead of the correct import (like react-icons/fa) and it breaks the app 15 | 16 | 17 | ## React 18 | - You either have a 300 line component, or you have 2 choices: prop drilling for 30 levels, or add context and properly type the context. Ugh. Especially typing the context is a PITA. 19 | 20 | ## Prisma 21 | - After running a db:migrate 22 | - I have to restart the dev server and studio 23 | - I have to go to the generated types so my editor (WebStorm) can pick up the type changes 24 | - Enums cannot be imported on the client side as values, only as types. At least in a Blitz app. Prisma says 25 | 26 | ## Blitz 27 | In retrospect, going with blitz was not a smart idea. trpc + next-auth is the way to go 28 | - Scaffolds are useful, but not that clever 29 | - my model has id string, but blitz scaffolds 10 files that use number as id, painful to refactor) 30 | - the scaffold is bad 31 | - I haaaaaaate creating files for every mutation, query, etc. while keeping a structure that makes blitz happy 32 | - I hate that blitz forces certain file structure, trpc doesn't 33 | - Not really Blitz fault, but the boilerplate comes with their own form logic 34 | - Oh you want to quickly use a form? Better remember the syntax for these 2 lines (FML) 35 | ``` 36 | export function TodoForm>(props: FormProps) { 37 | return key={props.initialValues?.toString()} {...props} formCtx={ctx}> 38 | ``` 39 | 40 | ## react-hook-form 41 | So annoying. Everything about it is annoying I honestly don't even know why I'm using it. 42 | - Banging my head against the wall because of "caching" issues. I'm navigating from one page to another page in Next.js, why does a form keep old values ??? It doesn't make any sense. 43 | 44 | ## Blitz/Next 45 | Not sure who's fault it is, figure it out. 46 | - When my page fully reloads, I want to punch a wall. Everything should hot reload. All the time. Always. 47 | --------------------------------------------------------------------------------