How I built currency conversion tooltips
In this technical retrospective (2022), @nicbou shares practical architectural lessons learned from running, scaling, or migrating production software under lean constraints.
Core Principles for Independent Builders:
Defaulting to simpler architectures (such as monolithic frameworks, SQLite, or managed VPS) prevents early engineering bankruptcy.
Evaluating true compute and egress costs reveals that high cloud bills can often be slashed by 80%+ through judicious re-platforming.
Code you write at 2 AM as a solo engineer must be easy to debug six months later without complex microservice dependencies.
Community Debate Themes:
HN engineers debated the tradeoffs between cloud convenience and raw server economics, database indexing strategies, and resisting premature architectural complexity.
CATEGORY Frugal Engineering →
HISTORICAL ERA Pandemic Bubble (2020–2022)
COMMUNITY SCORE 55 points
TOTAL DISCUSSIONS 13 comments
Some parts feel over-engineered, do you really need the most current rates, it's not like many currencies fluctuate wildly, unless you want to show crypto values. And people dealing with currencies know between them reading the info and the time they need to pay, the number might be different. Also their bank might have a different rate. So it seems like it's precision when a ~2% imprecision is good enough.
And needing to mouse-over all the numbers would annoy me quickly. Here's the peanut gallery suggestion: just like many sites have a language dropdown, add a dropdown to select the secondary currenc(ies), and all monetary values would then be displayed as e.g. "€175 (£150.05, $182.02)"
We've found that NextJS's Incremental Static Regeneration[0] hits the sweet spot for when we have needed to do this. Specifying a regeneration time allows us to say 'this data can be at most X seconds old' but if thousands of users hit a URL at once only one request is made.
[0] https://nextjs.org/docs/basic-features/data-fetching/incremental-static-regeneration ↗
:D
It'd be nice to add a `tabindex` value and add a `:focus` part to the tooltip CSS to make it appear for users navigating via their keyboard rather than mouse. If you look up 'accessible tooltips' there might be a few other tips.
That looks useful. I also built something kind of similar for currencies that I care about as well quite recently.
https://www.lloydatkinson.net/posts/2022/tiny-projects-currency-conversion-table/ ↗
Ouch, Brandenburg felt that one!
(Brandenburg is a federal state that is "known" for being quite rural and lacking all sorts of infrastructure...)