<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Leo Fu</title>
    <description>The latest articles on DEV Community by Leo Fu (@leo_fu_3fb908ef912caa7da9).</description>
    <link>https://dev.to/leo_fu_3fb908ef912caa7da9</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4271581%2Fbcac3aa1-8ae3-4612-b021-1a364ae48a39.png</url>
      <title>DEV Community: Leo Fu</title>
      <link>https://dev.to/leo_fu_3fb908ef912caa7da9</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/leo_fu_3fb908ef912caa7da9"/>
    <language>en</language>
    <item>
      <title>Why one extra kilometre adds fourteen hours to a pigeon flight model</title>
      <dc:creator>Leo Fu</dc:creator>
      <pubDate>Sun, 29 Nov 2026 02:16:14 +0000</pubDate>
      <link>https://dev.to/leo_fu_3fb908ef912caa7da9/why-one-extra-kilometre-adds-fourteen-hours-to-a-pigeon-flight-model-3n9b</link>
      <guid>https://dev.to/leo_fu_3fb908ef912caa7da9/why-one-extra-kilometre-adds-fourteen-hours-to-a-pigeon-flight-model-3n9b</guid>
      <description>&lt;p&gt;At 80 km/h, a pigeon in our flight model covers 800 km in exactly ten hours. Give it 801 km and the clock reads 24:00:45. The extra 45 seconds are easy to explain. The extra fourteen hours come from a boundary condition that is worth testing in any journey planner.&lt;/p&gt;

&lt;h2&gt;
  
  
  Count the gaps between flight blocks
&lt;/h2&gt;

&lt;p&gt;In Loftbound, readers can enable a hypothetical schedule with ten hours of flight followed by fourteen hours of rest. A rest starts only when there is still distance to cover. A journey that finishes exactly at the end of a block has no reason to wait until tomorrow.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Distance&lt;/th&gt;
&lt;th&gt;Time flying&lt;/th&gt;
&lt;th&gt;Intervening rests&lt;/th&gt;
&lt;th&gt;Elapsed time&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;799 km&lt;/td&gt;
&lt;td&gt;9:59:15&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;9:59:15&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;800 km&lt;/td&gt;
&lt;td&gt;10:00:00&lt;/td&gt;
&lt;td&gt;0&lt;/td&gt;
&lt;td&gt;10:00:00&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;801 km&lt;/td&gt;
&lt;td&gt;10:00:45&lt;/td&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;24:00:45&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These examples use a fixed ground speed, zero extra route allowance and the rest option switched on. In exact arithmetic the pause count is the number of flight blocks rounded up, minus one. Taking the floor instead would insert a rest at exactly 800 km. Our implementation also applies a small tolerance near a whole block so floating-point noise cannot add an overnight stop.&lt;/p&gt;

&lt;h2&gt;
  
  
  Choose the distance before starting the clock
&lt;/h2&gt;

&lt;p&gt;For coordinates we use GeographicLib’s WGS84 inverse calculation. It gives the shortest surface distance between the release point and the home loft. A bird can circle or deviate, so the interface keeps any extra route allowance visible. If someone already has a measured course distance, they can enter it directly.&lt;/p&gt;

&lt;p&gt;The practical test for the interface was whether a reader could explain the jump without reading the code. Showing flying time, pause count and elapsed time separately makes the result inspectable. Switch off rests and the 801 km example drops back to 10:00:45.&lt;/p&gt;

&lt;p&gt;You can reproduce the three cases in the known-distance calculator on &lt;a href="https://loftbound.com/" rel="noopener noreferrer"&gt;Loftbound&lt;/a&gt;. The rest schedule is a modelling choice you can change, not a prediction about when an individual bird will land.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Disclosure: This is our project. This write-up was prepared with AI assistance using the project's calculation code.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>algorithms</category>
      <category>science</category>
    </item>
    <item>
      <title>Building SinMirror: A Privacy-First 7 Deadly Sins &amp; Jungian Shadow Test with Next.js and Canvas</title>
      <dc:creator>Leo Fu</dc:creator>
      <pubDate>Sun, 29 Nov 2026 02:12:33 +0000</pubDate>
      <link>https://dev.to/leo_fu_3fb908ef912caa7da9/building-sinmirror-a-privacy-first-7-deadly-sins-jungian-shadow-test-with-nextjs-and-canvas-3p45</link>
      <guid>https://dev.to/leo_fu_3fb908ef912caa7da9/building-sinmirror-a-privacy-first-7-deadly-sins-jungian-shadow-test-with-nextjs-and-canvas-3p45</guid>
      <description>&lt;p&gt;Most online personality quizzes fall into two frustrating extremes: either they hide your results behind a surprise email/paywall at question 20, or they hand out generic, flattering labels that don't tell you anything useful about your blind spots.&lt;/p&gt;

&lt;p&gt;Over the past few weeks, I built &lt;strong&gt;&lt;a href="https://sinmirror.com" rel="noopener noreferrer"&gt;SinMirror&lt;/a&gt;&lt;/strong&gt; — a free, privacy-first &lt;strong&gt;7 Deadly Sins Personality Test &amp;amp; Jungian Shadow Mirror&lt;/strong&gt; that runs 100% client-side in the browser across 8 languages.&lt;/p&gt;

&lt;h2&gt;
  
  
  Live Demo &amp;amp; Core Modules
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Interactive Test (14-item Quick or 21-item Deep Mode):&lt;/strong&gt; &lt;a href="https://sinmirror.com" rel="noopener noreferrer"&gt;https://sinmirror.com&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;MBTI × 7 Deadly Sins Matrix (all 16 types):&lt;/strong&gt; &lt;a href="https://sinmirror.com/mbti" rel="noopener noreferrer"&gt;https://sinmirror.com/mbti&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;7 Deadly Sins Chemistry &amp;amp; Compatibility (49 pairings):&lt;/strong&gt; &lt;a href="https://sinmirror.com/compatibility" rel="noopener noreferrer"&gt;https://sinmirror.com/compatibility&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;42 Dual-Sin Shadow Archetypes Library:&lt;/strong&gt; &lt;a href="https://sinmirror.com/archetypes" rel="noopener noreferrer"&gt;https://sinmirror.com/archetypes&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Seven Heavenly Virtues Counter-Balance Guide:&lt;/strong&gt; &lt;a href="https://sinmirror.com/virtues" rel="noopener noreferrer"&gt;https://sinmirror.com/virtues&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Scoring &amp;amp; Psychological Methodology:&lt;/strong&gt; &lt;a href="https://sinmirror.com/science" rel="noopener noreferrer"&gt;https://sinmirror.com/science&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Engineering &amp;amp; Design Highlights
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Cross-Weighted Behavioral Scoring (Zero Server State)
&lt;/h3&gt;

&lt;p&gt;Instead of transparent "Are you an angry person?" questions, each scenario cross-weights primary and secondary shadow drives across &lt;strong&gt;Pride, Greed, Lust, Envy, Gluttony, Wrath, and Sloth&lt;/strong&gt;. All scoring runs in pure JavaScript in the browser—no database, no account wall, and compact URL codes (&lt;code&gt;/r/...&lt;/code&gt;) let friends compare profiles directly.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Dynamic 7-Axis SVG Radar Chart &amp;amp; 42 Fusion Archetypes
&lt;/h3&gt;

&lt;p&gt;Because nobody is defined by a single trait, combining the top Dominant Sin with the runner-up Shadow Sin yields &lt;strong&gt;42 distinct fusion archetypes&lt;/strong&gt; (e.g., &lt;em&gt;Pride × Greed&lt;/em&gt;, &lt;em&gt;Sloth × Pride&lt;/em&gt;, &lt;em&gt;Gluttony × Lust&lt;/em&gt;), rendered alongside a custom SVG radar polygon and an Inner Balance Index.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Client-Side HTML5 Canvas Tarot Share Cards
&lt;/h3&gt;

&lt;p&gt;To make sharing effortless on X, Instagram, and Reddit without server-side headless browser rendering costs, SinMirror draws crisp &lt;strong&gt;1080×1350 obsidian-and-gold tarot cards&lt;/strong&gt; directly onto an HTML5 &lt;code&gt;&amp;lt;canvas&amp;gt;&lt;/code&gt; for instant PNG download.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Static Pre-Rendering Across 8 Locales
&lt;/h3&gt;

&lt;p&gt;Built with the Next.js App Router, every archetype, virtue, zodiac, and MBTI guide is statically generated across English, Spanish, Japanese, Chinese, Portuguese, Korean, French, and German with full &lt;code&gt;hreflang&lt;/code&gt; alternates and structured JSON-LD.&lt;/p&gt;




&lt;p&gt;If you try the quick 2-minute mirror at &lt;strong&gt;&lt;a href="https://sinmirror.com" rel="noopener noreferrer"&gt;sinmirror.com&lt;/a&gt;&lt;/strong&gt;, I'd love to hear what Dominant × Shadow archetype you got—and any feedback on the UI or scoring feel!&lt;/p&gt;

</description>
      <category>showdevnextjswebdevjavascript</category>
    </item>
  </channel>
</rss>
