Amit
Amit
Explore posts from servers
TTCTheo's Typesafe Cult
Created by gave_one on 8/8/2023 in #questions
Error validating: You defined the enum `UserRole`. But the current connector does not support enums.
is it using sqlite connector ? as the error says, all connectors donot support enum. sqlite doesn't afaik
19 replies
TTCTheo's Typesafe Cult
Created by Lopen on 1/28/2023 in #questions
best way to handle image upload in t3 stack
@Lev the main problem why TRPC can't do this is because of json is a textual format, so sending binary data requires additional encoding (base64 can be used). This works for small files but for large files it wastes a lot of bandwidth and processing power. Also, TRPC does not want to fix this as far as I know(if the serialisation format is changed to something like msgpack etc you can send images as it is). Since TRPC is out of question, alternative is creating a custom api end point if you want to avoid cloud storage. Hypothetically, if you used zodios, ts-rest this wouldn't be a problem since they allow multi part form data. But in that case, you are depending on less mature libraries and loose the abstraction that TRPC provides (zodios/ts-rest are less abstract so knowing how http status codes/error handling works is required). Imo, since there are a very few cases where you need large file upload, I will just keep using TRPC and handle the rare cases with api endpoints.
42 replies
TTCTheo's Typesafe Cult
Created by zendev on 4/19/2023 in #questions
File storage with T3
It's not a wrapper it's s3 api compatible
48 replies
TTCTheo's Typesafe Cult
Created by Lopen on 4/22/2023 in #questions
Google analytics 4 very difficult to setup
@Lopen32
10 replies
TTCTheo's Typesafe Cult
Created by Lopen on 4/22/2023 in #questions
Google analytics 4 very difficult to setup
You should be able to see those in Reports -> Behavior -> Site Content
10 replies
TTCTheo's Typesafe Cult
Created by Lopen on 4/22/2023 in #questions
Google analytics 4 very difficult to setup
Any chance you are using cloudflare cdn ? In cloudflare you can integrate using zaraz which is a more efficient way to integrate third party scripts. It works similar to partytown.
10 replies
TTCTheo's Typesafe Cult
Created by zendev on 4/19/2023 in #questions
File storage with T3
@JulieCezar did you try cloudflare r2, it seems to be cheaper than everything else
48 replies
TTCTheo's Typesafe Cult
Created by zendev on 4/19/2023 in #questions
File storage with T3
Any S3 compatible cloud object storage provider seems to be good. Cloudflare R2 is basically free for small projects. Digitalocean spaces is cheaper than S3.
48 replies
TTCTheo's Typesafe Cult
Created by Hycord | @ When Replying on 4/18/2023 in #questions
dockerizing typescript
What registry should I use?
Github container registry should be good. I like dockerhub. There is also an option to selfhost the registry using something like harbor(golang).
Can I deploy docker files on Vercel if I have a web app inside it?
You can't deploy docker images to vercel. https://vercel.com/guides/does-vercel-support-docker-deployments
4 replies
TTCTheo's Typesafe Cult
Created by Ani on 4/18/2023 in #questions
keyboard purchase
Try to decide on the following, 1. Sound - Silent types vs clicky ones 2. Key press feel - tactile vs linear 3. Backlit and keycaps - even when the keyboard has backlit, the keycaps might not allow shine through. Then there are things like north facing/south facing led position. 4. Hot-swappable - is it possible to change the keyswitches 5. Keyboard layout - Personally i like 80% TKL which has the Insert key (on windows and some terminal programs use shift insert for paste) 6. Wireless/Non wireless I have the CIDOO ABM084 which also has a volume knob. Keychron k8 pro also feels like a good option. I got the keychron k2 v2 earlier but the layout (75% TKL) feels a bit crammed.
20 replies
TTCTheo's Typesafe Cult
Created by Amit on 4/10/2023 in #questions
trpc alternatives like zodios, ts-rest
@iway1 Thanks for the insights. I have not yet tried the new libraries. It will be interesting to see how they compare dx and stability wise.
4 replies
TTCTheo's Typesafe Cult
Created by Mendy on 2/19/2023 in #questions
PostgreSQL: Best pgAdmin4 Alternative?
If you just need a GUI tool to easily query the DB, I think you can try Hasura Community Edition.
13 replies
TTCTheo's Typesafe Cult
Created by Shoodey on 2/16/2023 in #questions
Send large data (~5MB) to trpc backend
Hmm, how about not uploading anything and doing everything at client side(in the browser). I guess there are some libraries for this. A quick search leads to https://github.com/sql-js/sql.js/
21 replies
TTCTheo's Typesafe Cult
Created by Amit on 2/12/2023 in #questions
Good way to run single file script with NextJS
I tried this. I was running into some errors again such as "SyntaxError: Cannot use import statement outside a module ". Adding
"ts-node": {
"compilerOptions": {
"module": "CommonJS"
}
}
"ts-node": {
"compilerOptions": {
"module": "CommonJS"
}
}
to tsconfig.json, fixed it.
4 replies
TTCTheo's Typesafe Cult
Created by Amit on 2/12/2023 in #questions
Good way to run single file script with NextJS
@kapobajza thanks a lot, let me try that
4 replies