跪拜 Guibai
← All articles
Frontend · JavaScript · Programmer

The Frontend Engineer's Playbook for Saying No Without Saying No

By ErpanOmer ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Frontend engineers who can't articulate technical boundaries end up owning impossible deadlines and production failures. This pattern — state the limit, price the alternatives, return the decision — turns a confrontation into a collaboration and protects both the system and the engineer's reputation.

Summary

Senior frontend engineers don't refuse unreasonable demands; they reframe them as trade-offs. When a product manager asks for 100,000 DOM nodes in an infinite scroll, a sub-second load time on a slow backend, or client-side encryption of PII, the response isn't a flat no. It's a breakdown of the browser's physical limits, the full network chain, or the transparency of frontend code, followed by a concrete alternative with a clear cost. The technique works across four common scenarios: massive DOM rendering, performance targets, mobile drag-and-drop, and local encryption. In each case, the engineer names the technical ceiling, proposes a cheaper path, and asks the product manager to choose. The underlying move is risk assessment and cost accounting delivered in the product manager's own language — business impact. The final step is handing the decision back, so the product manager owns the safer choice rather than feeling overruled.

Takeaways
Browsers crash when DOM node counts exceed roughly 5,000 on low-end Android devices; 100,000 rich-text items can generate 300,000 nodes.
Virtual scrolling keeps the visible DOM to 20–30 items, cutting memory from gigabytes to tens of megabytes at the cost of about two extra development days.
A 1-second page-load target spans DNS, TCP, TLS, backend response, CDN, and frontend rendering; the frontend controls only the final segment.
Frontend encryption is security theater — keys and algorithms are visible in DevTools, so real encryption must happen server-side or via a backend-issued public key.
Mobile drag-and-drop conflicts with native scroll behavior and demands weeks of state management and animation work; a long-press menu can deliver the same outcome in days.
Never say "this can't be done"; say "it can be done, but the cost is X, and here are alternatives A, B, and C."
After laying out the options, ask the product manager to decide — it preserves their authority and your relationship.
Conclusions

The core skill isn't technical depth alone; it's translating that depth into business-risk language that a non-engineer can act on.

Framing a refusal as a set of priced alternatives shifts the conversation from a personal standoff to a shared business decision.

The advice to let the product manager make the final call is a power move disguised as deference — it makes the safer technical path feel like their own idea.

Concepts & terms
Virtual Scroll
A rendering technique that keeps only the DOM nodes visible in the viewport mounted, recycling them as the user scrolls, so a list of any length uses a constant, small number of nodes.
DOM node limit
Browsers have a practical ceiling on simultaneously mounted DOM nodes; exceeding roughly 5,000 nodes on low-end mobile devices causes frame rates to drop sharply, leading to visible lag or crashes.
Frontend encryption
Encrypting data in the browser is ineffective for secrecy because all JavaScript source, keys, and algorithms are visible to the user via DevTools; real confidentiality requires server-side or asymmetric encryption where the private key never leaves the server.
From the discussion

The discussion splits between those who see the article's approach as genuine rejection and those who call it elegant implementation under a different name. A competing view insists that direct refusal is the true mark of professionalism, while a lengthy contribution reframes the entire dynamic as turning opposition into joint decision-making through cost breakdowns, alternatives, and documented process. The tension is whether the playbook actually says no or merely dresses up a yes.

Calling the article's method 'elegant rejection' is a misnomer — it describes elegant implementation, not refusal.
Directly rejecting unreasonable requirements is what demonstrates real professional competence.
Turning PM confrontation into joint decision-making requires replacing 'I won't do it' with quantified cost and timeline impacts.
Offering a lower-cost Plan B that addresses the underlying user pain point is more effective than debating the PM's proposed solution.
Framing pushback around concrete performance risks (e.g., FCP degradation on low-end devices) leverages the frontend engineer's domain authority.
Mandating that requirement changes be documented in the PRD and reflected in scheduling creates process friction that naturally filters frivolous requests.
A PM's casual suggestion often forces the frontend engineer into an unplanned technical education session.
Featured comments
天涯没有海角 2 likes

This isn't rejecting the requirement at all — you're implementing it elegantly, not rejecting it elegantly~

ErpanOmer

[Grin][Grin][Grin]

River_何 1 likes

Rejecting when you should reject is what demonstrates genuine professional competence. Here's a recommendation for a popular app that many frontend devs are using: visualization-collection, a collection focused on frontend visual effects. It includes hundreds of examples of rich CSS animations, Canvas animations, Three.js 3D, and more — and it's open-source and free. App URL (desktop): https://hepengwei.cn Source code: https://github.com/hepengwei/visualization-collection

mahmad786cloud

When facing unreasonable requirements from a PM, both 'clashing head-on' and 'accepting everything wholesale' are inefficient. The key to elegant rejection lies in turning 'opposition' into 'joint decision-making,' using data, cost, and alternative solutions to make your case. Here are 4 very practical communication strategies: 1. Break down the cost — use 'resources and timeline' instead of 'I won't do it.' Don't say 'this can't be done' directly; help the PM do the math. Communication template: 'This feature is technically feasible, but with the current design it would require changes to the underlying architecture, adding an estimated 3 days to the development cycle and potentially delaying the on-time launch of modules A and B. Should we delay the launch, or move this feature to Phase 2?' 2. Clarify 'boundaries and priorities,' and provide an alternative (Plan B). PMs often propose 'the solution they imagine' rather than addressing the real user pain point. You can replace it with a lower-cost frontend implementation. Communication template: 'If the core goal is to improve conversion rates, the current approach is too costly. We could start with a simplified version (e.g., changing the pop-up to a non-blocking toast), launch it to see the data feedback, and then decide whether to refactor.' 3. Raise professional risks around 'performance and user experience.' The frontend is the layer closest to the user; performance and experience are your professional moat. Communication template: 'Loading this complex 3D animation/large image list on the first screen will increase FCP (First Contentful Paint) by 1.5 seconds on low-end devices, severely impacting retention. I suggest switching to a CSS animation or lazy loading.' 4. Document requirement changes to make the decision process transparent. If the PM insists on adding an unreasonable requirement, don't agree verbally — ask for it to be reflected in the PRD and update the scheduling cards. With process constraints, PMs will naturally be more cautious when proposing requirements. Summary: An excellent engineer is not an 'order-taker' but a 'technical consultant.' The highest form of rejection is making the PM feel you are helping them avoid pitfalls and ensuring the project is delivered on time and with high quality. 👉 Also recommending: If you need to quickly look up clean, ad-free frontend and backend basic code in your daily development, feel free to try our quick-reference Playground: https://a1lab.tech

See top comments, translated →
Source: juejin.cn ↗ Google Translate ↗ Backup ↗