DevIdiot!
Install PM2
Originally posted on Web Warrior ToolboxOn a server where youâve already installed npm or pnpm, you can add PM2 to manage your backend application.If youâre not sure about your fnm/pnpm setup, check this tutorial. Why PM2?PM2 provides features you donât get by simply running npm run start or pnpm run dev:Simple start â pm2 start dist/main.jsHealth check â pm2 ls shows running appsAutoârestart on reboot â configure with pm2 startupConsistency â same commands everywhere, instead of arbitrary
The Day I Stopped Correcting My AI Was the Day I Understood What Rules Actually Do.
For a long time correcting the AI was just part of the process.Generate. Review. Fix the structure. Fix the naming. Move the logic to the right place. Ask again. Get something closer. Fix that too.I thought that was normal. I thought that was just how working with AI worked. You prompt, you steer, you correct, you move on.It took me a while to realize that the corrections were not a feature of the workflow. They were a symptom of a broken one. What the corrections were actually telling meEv
Know Your WebDev Math: Dynamic positioning with trigonometry
When I needed to pass Calculus and Algebra during my Computer Science degree, I used the formula known to every Polish student called 'ZZZ' (ZakuÄ, ZdaÄ, ZapomnieÄ) - Cram, Pass, Forget. It means memorizing just enough to pass the exam and then not caring if you'll remember any of it later.Fast forward a few years into my web developer career and I needed to implement a mouseMove event on the SVG element. Every move I made with my mouse made the element's position shoot off into the void. I solv
Please Use AI
<a href="https://news.ycombinator.com/item?id=48323101">Comments</a>
Mistakes I Made Building My First SaaS Starter Kit
Over the past few weeks, I worked on building my first reusable SaaS starter kit using Next.js, Prisma, JWT authentication, and Lemon Squeezy billing.The goal was simple:Stop rebuilding the same foundation every time I start a new SaaS idea.But while building it, I made a lot of mistakes â and honestly, those mistakes taught me more than the successful parts.Here are some of the biggest lessons I learned.1. I Tried to Build Everything at OnceAt the beginning, I wanted the starter kit to include:
Understanding useReducer and useRef in React
Mastering State and References: A Deep Dive into useReducer and useRef for Professional React DevelopersWe've all been there: a React component starts simple, maybe a few useState calls, a couple of props. Then, the feature requests roll in. Suddenly, your useState calls are multiplying, updates depend on previous values, and you're dispatching multiple setters in a single handler just to keep the UI in sync. Chasing down a bug in a component with ten useState variables is, in my experienc
A Taxonomy of Shopify App-Theme Conflicts: 147 Issues Classified
Our first three articles documented the damage: 53 stores, 147+ conflicts, CSS specificity cascading in 70% of cases, z-index values exceeding 90,000 in five stores. We've also published two technical guides â one on debugging workflows, one on CSS specificity mechanics.This article does something different. It's a classification framework â a taxonomy of the conflict types we found, organized so that when you encounter a new conflict, you can reason about it precisely instead of guessing.The ta
One Open Source Project per Day #79: Twenty - Defining the Modern Open-Source CRM Alternative to Salesforce
Introduction"CRM should not be a heavy, closed, and expensive black box."This is the 79th article in the "One Open Source Project per Day" series. Today, we are discussing the leading player in the open-source CRM space: Twenty.When people think of CRM (Customer Relationship Management), the first thing that often comes to mind is Salesforce: powerful but with a dated UI, closed-source, and extremely expensive. For modern developers and agile SMBs, these "old-school" systems struggle to ke
đĽ Customize Joget Inbox Lists with JavaScript
1. OverviewThis article shows how to customize a Joget inbox or datalist using JavaScript. The script moves row action columns, localizes filter labels and buttons, adds clear icons to text filters, and formats status cells with CSS-friendly labels. 2. How It WorksMove action columns to the first position for easier access.Update filter placeholders using Joget hash variables.Rename inbox action links such as approve/reject or resubmission.Add clear buttons beside text filters.Convert
đ§Ž Update Joget Form Grid Cells with JavaScript
1. OverviewThis article shows how to add rows to a Joget Enterprise Form Grid and update a specific cell value with JavaScript. The example also recalculates a row number after grid changes. 2. How It WorksRead selected form values when the button is clicked.Validate required values before adding a row.Call the grid's generated add function.Store row data as JSON.On grid change, loop through rows and update a target cell.Use enterpriseformgrid("fillValue", ...) to write the updated JS
Shopify Data Mapping Strategies: Patterns That Prevent Silent Integration Failures
Poor data quality costs $12.9M per year on average (Gartner, 2022). In Shopify integrations, the failure mode is specific: an unmapped field silently drops a value, an incorrect type coercion truncates a price, a missing enum routes an order to the wrong fulfillment channel.Here is the complete mapping architecture that prevents each failure type.The 8 Mapping Patterns Reference Pattern Use Case Complexity Failure Risk Direct field mapping Same dat
Error Propagation with Custom Error Types
Error Propagation with Custom Error Types in JavaScript Historical and Technical ContextError handling has been a fundamental part of programming languages since their inception, and JavaScript is no exception. The language evolved primarily on the client side, where dynamic content and user interaction necessitated graceful error management. Traditional approaches used the generic Error class, which, while functional, didnât provide the necessary granularity for complex applications.
Stop Using WebSockets for Everything đ¨
When developers hear "real-time communication," the first thing that comes to mind is usually WebSockets.But here's the thing:WebSockets are not always the best solution.Choosing the wrong real-time technology can add unnecessary complexity, infrastructure costs, and maintenance headaches.Let's look at some alternatives and when you should use them. 1. Server-Sent Events (SSE)SSE allows the server to push updates to the client over a regular HTTP connection.Perfect for:â
Live dashboardsâ
No
JavaScript
JavaScript is one of the most popular programming languages in web development. It is mainly used to make websites interactive and dynamic. With JavaScript, we can create things like buttons, animations, calculators, login forms, games, and much more. VariablesVariables used to store data in JavaScript. JavaScript has 3 ways to create variables:varletconstvarvar has global scope and it is the old way of declaring variables.var a = 10;console.log(a);output:10letlet has block scope. It c
Advanced Hooks & State Management Patterns in React
Read Time: ~14 minutes | Building on React fundamentals to master state management at scalePrerequisites: Familiarity with React basics, useState, useEffect (Part 1) đ Series Navigationâ Part 1: Complete Guide from Zero to ProductionPart 2: Advanced Hooks & State Management â YOU ARE HEREâ Part 3: Performance Optimization (coming next) đ What You'll LearnBy the end of this guide, you'll understand:â
Creating powerful custom hooksâ
When and how to use useReducerâ
Managing state glob
Local Git Remotes
<a href="https://news.ycombinator.com/item?id=48322389">Comments</a>
This Week In React #283: TanStack, RSC, Liquid DOM, Performance| Expo, Reanimated, worklets, NativeScript | TC39, npm, pnpm, Node.js
Hi everyone, Seb and Jan here đ!This week we have great deep dive blog posts about data fetching (TanStack vs Next.js) and performance (GitHub and Linear).On the React Native side, Expo dropped a major SDK with Expo UI stable. Reanimated leverages the shared animation backend and improves CSS animations on iOS.Supply chain security remains an important topic. npm introduced staged publishing workflows, and will block postinstall scripts by default in the near future.đĄ Subscribe to the official n
Poll: How often do you check "newest"?
<a href="https://news.ycombinator.com/item?id=48322267">Comments</a>
High Density Living, 2000 Years Ago: Inside the Roman Apartment Building
<a href="https://news.ycombinator.com/item?id=48322241">Comments</a>
The UK Government's Low Value Purchase System Is a Waste of Time
<a href="https://news.ycombinator.com/item?id=48322154">Comments</a>