Ovidius
Ovidius
TTCTheo's Typesafe Cult
Created by Wiznet on 8/1/2024 in #questions
API Patching Strategy
In a case like this I would update the whole object everytime. I break when they are too many and there is some logical grouping. It's nice to have it separated but It seems much more code for too small performance gain.
4 replies
TTCTheo's Typesafe Cult
Created by Palascat on 7/7/2024 in #questions
do you query the localstore everytime to get the token before making api calls ?
1. I subscribe to what @Jotas said 2. It's fine to pickup the token with every api call I am using auth0 oidc with actions: User logs in and an encrypted session token gets saved in a cookie. Every time the users opens a page requiring data from an api, the action requests a new access token (with the refresh token) and uses it to further call the backend.
5 replies
TTCTheo's Typesafe Cult
Created by johnny the fifth on 6/30/2024 in #questions
Do i use server components , actions over express JS for my App
OAuth/OIDC .. it's industry standard with identity, refresh and access tokens. There are 3rd party identity management platforms which implements the standards and you can leverage them for a fast solution. It's a complex topic with an entire industry around it. Regarding actions or express backed it depends on each use case, I am using both. You could use just nextjs + actions probably, it simplifies everything which is what you initially should target for. I see it as a matter of what is your target with the chat app... what are the requirements.
14 replies
TTCTheo's Typesafe Cult
Created by Ovidius on 6/28/2024 in #questions
Outbox pattern with mariadb and rabbitmq
I started to implement it and writting also an article if anyone it's interested in this for microservices: https://wipsquare.dev/2024/06/28/microservices-transactional-outbox-pattern-part-1/
3 replies
TTCTheo's Typesafe Cult
Created by A Reptilian on 6/27/2024 in #questions
Most efficient monolith structure to have an Express.js REST API with Next.js SSR client?
Hi, it's not clear to me what you're trying to do, but it seems you want to run a nextjs and express as different (or combined) instances with common modules and files. Not sure if it's even possible but I would not even try it. How I see it: Option 1 If you want a separate backend running with express, keep it as separate application in it's own repo. The frontend, nextjs, a different application in it's own repo. You run them both locally on different ports or containerized. Option 2 (probably easiest to manage) You do everything in the nextjs project since it has backend and frontend capabilities.
4 replies
TTCTheo's Typesafe Cult
Created by DugeHick on 6/18/2024 in #questions
Has anyone tried using prisma just for migrations, and using drizzle for querying on Postgres DB?
Hi, I'm using prisma just for migrations but with MariaDB and all the queries are standard sql... I guess I don't see yet the value of ORM in querying the DB but just in managing the schema.
5 replies