adomaitis
TTCTheo's Typesafe Cult
•Created by adomaitis on 8/2/2023 in #questions
NextJS recursively call API route.ts from API route.ts
lmao this was dumb, I can make external function and import them wherever I need.
I made a delete.ts file where:
deleteElement deletes all related to the element, including stuff from supabase storage.
deletePlace deletes the place and its places and its elements, by calling itself and deleteElement.
deleteSite does the same.
4 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 3/8/2023 in #questions
Next 13 + NextAuth - Redirect on the server
4 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 3/8/2023 in #questions
Next 13 + NextAuth - Redirect on the server
found a workaround: https://github.com/vercel/next.js/issues/46493
4 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 3/8/2023 in #questions
Next 13 + NextAuth - Redirect on the server
Trying to follow NextAuth documentation:
error:
4 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
it worked
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
thx
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
cool
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
trying it
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
oh shit
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
do you mean on the cleanup?
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
function printNumberFive() {
console.log(5);
}
useEffect(() => {
scrollRef.current!.addEventListener("scroll", () => {
printNumberFive();
});
return () => {
scrollRef.current!.removeEventListener("scroll", () => {
printNumberFive();
});
};
}, [selectedItem]);
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 2/16/2023 in #questions
useEffect being weir - EventListener
Yeah that is not working also
16 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 1/17/2023 in #questions
Prisma + Planetscale TLS/SLL error
had .env file with the db url and .env.local with an empty db url.
somehow the prisma was getting the right one to push and to use prisma studio but not for finding shit in the db
4 replies
TTCTheo's Typesafe Cult
•Created by adomaitis on 1/17/2023 in #questions
Prisma + Planetscale TLS/SLL error
nvm solved it
4 replies