<?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: Ricardo Moura</title>
    <description>The latest articles on DEV Community by Ricardo Moura (@rmoura98_).</description>
    <link>https://dev.to/rmoura98_</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%2F4259242%2F601cc414-ecef-4c52-bb53-14febb65be00.jpg</url>
      <title>DEV Community: Ricardo Moura</title>
      <link>https://dev.to/rmoura98_</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/rmoura98_"/>
    <language>en</language>
    <item>
      <title>I built an open-source LookAway alternative with Tauri and Rust</title>
      <dc:creator>Ricardo Moura</dc:creator>
      <pubDate>Sun, 22 Nov 2026 19:40:23 +0000</pubDate>
      <link>https://dev.to/rmoura98_/i-built-an-open-source-lookaway-alternative-with-tauri-and-rust-1kfh</link>
      <guid>https://dev.to/rmoura98_/i-built-an-open-source-lookaway-alternative-with-tauri-and-rust-1kfh</guid>
      <description>&lt;p&gt;By 5pm my eyes used to feel like sandpaper.&lt;/p&gt;

&lt;p&gt;The fix is famously boring: every 20 minutes, look at something about 20 feet (6 m) away for 20 seconds. It lets the focusing muscles in your eyes relax. The hard part isn't the rule. It's remembering it, and following it without being yanked out of whatever you're in the middle of.&lt;/p&gt;

&lt;p&gt;The nicest app I found for this was &lt;a href="https://lookaway.com" rel="noopener noreferrer"&gt;LookAway&lt;/a&gt;. It's beautifully done, but it's Mac-only and paid, and I spend most of my day on Windows. So I built a free, open-source, cross-platform one: &lt;strong&gt;&lt;a href="https://github.com/RMoura98/yonder" rel="noopener noreferrer"&gt;Yonder&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F818gjitfis1gazrmjdxj.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F818gjitfis1gazrmjdxj.gif" alt="Yonder: a heads-up card counts down, a small countdown follows the cursor, then the desktop blurs into the break screen" width="599" height="375"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What makes a break reminder annoying
&lt;/h2&gt;

&lt;p&gt;Before writing any code, I listed what made me turn other break apps off:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Breaks that land mid-sentence.&lt;/strong&gt; Nothing kills a habit faster than a full-screen overlay while you're typing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No warning.&lt;/strong&gt; You need a few seconds to finish a thought.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Breaks during calls and presentations.&lt;/strong&gt; Instant uninstall.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Feeling punished.&lt;/strong&gt; A break screen should feel like a breather, not an error dialog.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;So Yonder:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;shows a &lt;strong&gt;heads-up card&lt;/strong&gt; before each break, with &lt;em&gt;start now / +1m / +5m / +15m&lt;/em&gt;;&lt;/li&gt;
&lt;li&gt;shows a small &lt;strong&gt;countdown that follows your cursor&lt;/strong&gt; for the last five seconds;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;waits while you're typing&lt;/strong&gt;, for up to 30 seconds;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;holds breaks&lt;/strong&gt; while your mic or camera is in use, during fullscreen apps (Windows for now), or while apps you choose are open;&lt;/li&gt;
&lt;li&gt;counts time away from the computer as a break, so you don't get one the moment you sit back down;&lt;/li&gt;
&lt;li&gt;and the break itself &lt;strong&gt;blurs your actual desktop&lt;/strong&gt; behind a calm countdown, then sharpens it back.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why Tauri instead of Electron
&lt;/h2&gt;

&lt;p&gt;A break reminder runs all day, every day, in the background. Bundling an entire browser for that felt wrong.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://tauri.app" rel="noopener noreferrer"&gt;Tauri&lt;/a&gt; uses the operating system's own webview (WebView2 on Windows, WebKit on macOS and Linux) with a Rust core. The result:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the Windows installer is &lt;strong&gt;1.3 MB&lt;/strong&gt;, and the universal macOS &lt;code&gt;.dmg&lt;/code&gt; is &lt;strong&gt;3.6 MB&lt;/strong&gt;;&lt;/li&gt;
&lt;li&gt;the UI is &lt;strong&gt;plain HTML, CSS and JavaScript&lt;/strong&gt;, with no framework and no bundler;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;windows only exist while they're on screen.&lt;/strong&gt; Between breaks Yonder is a tray icon and one sleeping thread.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The scheduler is a state machine
&lt;/h2&gt;

&lt;p&gt;The core of Yonder is a single function that runs once a second:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight rust"&gt;&lt;code&gt;&lt;span class="k"&gt;pub&lt;/span&gt; &lt;span class="k"&gt;fn&lt;/span&gt; &lt;span class="nf"&gt;tick&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="kd"&gt;mut&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;idle_secs&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kt"&gt;u64&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;smart_pause&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kt"&gt;Option&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="kt"&gt;String&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="kt"&gt;Vec&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Effect&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// ...count active screen time, handle idle and smart pause...&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prebreak_enabled&lt;/span&gt;
        &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prebreak_shown&lt;/span&gt;
        &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;work_secs&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;lead&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="n"&gt;interval&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prebreak_shown&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="n"&gt;fx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;push&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nc"&gt;Effect&lt;/span&gt;&lt;span class="o"&gt;::&lt;/span&gt;&lt;span class="nc"&gt;ShowPrebreak&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;work_secs&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="n"&gt;interval&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;wait_while_typing&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="n"&gt;idle_secs&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;typing_wait&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;30&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;typing_wait&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c1"&gt;// still typing: wait politely&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="nb"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;start_scheduled_break&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="kd"&gt;mut&lt;/span&gt; &lt;span class="n"&gt;fx&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="n"&gt;fx&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The important part: &lt;strong&gt;it never touches a window.&lt;/strong&gt; It returns a list of &lt;code&gt;Effect&lt;/code&gt;s (&lt;code&gt;ShowPrebreak&lt;/code&gt;, &lt;code&gt;StartBreak&lt;/code&gt;, &lt;code&gt;EndBreak&lt;/code&gt;, &lt;code&gt;ShowReminders&lt;/code&gt;, &lt;code&gt;Lock&lt;/code&gt;…), and a thin layer applies them. That keeps the logic easy to reason about and easy to test, which is also an &lt;a href="https://github.com/RMoura98/yonder/issues/3" rel="noopener noreferrer"&gt;open good-first-issue&lt;/a&gt; if you want to help.&lt;/p&gt;

&lt;h2&gt;
  
  
  Making the break feel smooth
&lt;/h2&gt;

&lt;p&gt;The effect I'm proudest of is the blurred-desktop break, and it's surprisingly simple:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Just before the break, take a screenshot of each monitor.&lt;/li&gt;
&lt;li&gt;Open a borderless, &lt;strong&gt;transparent&lt;/strong&gt; window on each display. Since it's transparent, the first frame looks exactly like your desktop.&lt;/li&gt;
&lt;li&gt;Put the screenshot in it and animate a CSS &lt;code&gt;filter: blur()&lt;/code&gt; from 0 to 42px. Your desktop appears to melt in place.&lt;/li&gt;
&lt;li&gt;At the end, animate the blur back to 0 and &lt;strong&gt;cross-fade the whole window out&lt;/strong&gt;, so the hand-off to the real desktop has no visible jump.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The odometer-style countdown is just one column of digits per position, translated with a springy &lt;code&gt;cubic-bezier&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Knowing when you're busy, without heavy dependencies
&lt;/h2&gt;

&lt;p&gt;The OS integrations stay deliberately small:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Idle time:&lt;/strong&gt; &lt;code&gt;GetLastInputInfo&lt;/code&gt; on Windows, &lt;code&gt;CGEventSourceSecondsSinceLastEventType&lt;/code&gt; on macOS, and &lt;code&gt;xprintidle&lt;/code&gt; or GNOME's idle monitor on Linux.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;In a call:&lt;/strong&gt; Windows records which apps are using the microphone or camera in the registry (&lt;code&gt;CapabilityAccessManager&lt;/code&gt;). If an entry has a start time but no stop time, something is recording.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Fullscreen:&lt;/strong&gt; &lt;code&gt;SHQueryUserNotificationState&lt;/code&gt;, plus a check that the foreground app is a browser or video player, because borderless maximized terminals also report as "busy". I found that one when Yonder refused to give &lt;em&gt;me&lt;/em&gt; a break.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even the tray icon has no image files. It's a 16-unit vector glyph rasterized at runtime with 4×4 supersampling, so it re-tints black or white when you switch the Windows taskbar theme.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;macOS:&lt;/strong&gt; &lt;code&gt;brew tap rmoura98/yonder https://github.com/RMoura98/yonder &amp;amp;&amp;amp; brew install --cask yonder&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Windows and Linux:&lt;/strong&gt; installers on the &lt;a href="https://github.com/RMoura98/yonder/releases/latest" rel="noopener noreferrer"&gt;releases page&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's MIT licensed, with no account and no telemetry. Builds aren't code-signed yet, so Windows SmartScreen will ask you to confirm ("More info → Run anyway").&lt;/p&gt;

&lt;h2&gt;
  
  
  Help wanted
&lt;/h2&gt;

&lt;p&gt;This is the first release, and there's plenty left to build:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/RMoura98/yonder/issues/4" rel="noopener noreferrer"&gt;fullscreen detection on macOS&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/RMoura98/yonder/issues/5" rel="noopener noreferrer"&gt;blurred and split-screen breaks on Linux&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/RMoura98/yonder/issues/6" rel="noopener noreferrer"&gt;code signing and notarization in CI&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/RMoura98/yonder/issues/1" rel="noopener noreferrer"&gt;more break sounds&lt;/a&gt; and &lt;a href="https://github.com/RMoura98/yonder/issues/2" rel="noopener noreferrer"&gt;split-screen textures&lt;/a&gt;, both good first issues&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/RMoura98/yonder/issues/8" rel="noopener noreferrer"&gt;testing on multi-monitor setups&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you try it, I'd love to hear how it goes, especially on Linux and multiple monitors. And if it saves your eyes a little, a ⭐ on &lt;a href="https://github.com/RMoura98/yonder" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt; helps other people find it.&lt;/p&gt;

&lt;p&gt;Now go look at something far away. 👀&lt;/p&gt;

</description>
      <category>rust</category>
      <category>opensource</category>
      <category>showdev</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
