Profile avatar
nabanitasarkar.com
Software developer focused on frontend engineering. I also dabble with design from time to time.
23 posts 21 followers 97 following
Regular Contributor
Conversation Starter

Making a function for route validation (body, params, query) so that in the main controller req.body etc is properly typed in @expressjs.bsky.social with zod. It is still cooking, but if it is successful then it would be a blessing. Otherwise in express codebase using typescript becomes a nightmare

I recreated a cool React Motion demo by @lndev.bsky.social with only CSS view transitions and a bit of JavaScript. I explain this in detail in the upcoming edition of Modern Web Weekly. Check the codepen, link to the original demo and the subscription link 👇 🧵1/4

🧑‍🎄 Node.js now supports TypeScript by default 🤯 🎄

Anyone using #mongoose for @mongodb.bsky.social in @expressjs.bsky.social with @typescriptlang.org ? The typing is basically non existent in Mongoose. Is it supposed to be just accepted? In a typescript express backend, it is basically nullifying all the benefits of typescript

Today's discovery #3 Validator.js validates string only. If number is provided in the body json, then validation will not behave as intended and might give absolutely wrong errors also

Today's discovery #2 In Express middleware if next() is used in the middle portion of a middleware it actually doesn't short circuit. To short circuit we MUST `return next()` Otherwise, next() will go to the next middleware/controller and from this one, it is possible to go back to the first one

Today's discovery - IF javascript is disabled in the browser, <noscript> element content shows up as string. If JS is enabled then the content is parsed and showed properly with syntax highlighting. Wicked! 🤯 And it makes sense. And I was wondering what did I do wrong!

It took me back to the world where access to internet was sparse, smart phones were still not a thing. Connecting with people in real life took efforts, maintaining it even more. When we achieve all these, in the end game, we lose cuz we give up human touch? Should't it all be by humans for humans?

Finally used @astro.build AND it was the tool I wanted forever for building landing pages and marketing sites. I guess many people purchase themes and many a time those are not available in their preferred framework — only in html/css. In that case Astro has been the most seemless experience so far

Here's a cool 3D effect on @codepen.io: codepen.io/thebabydino/pen/PogJybr No text duplication whatsoever, no images save for #CSS gradients creating the dot #pattern. The #3D effect and outline are made from #SVG #filter magic.🪄 An entry for this week's #CodePenChallenge.