<?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 Wong</title>
    <description>The latest articles on DEV Community by Leo Wong (@leo_wong_12555ba8c901c8ce).</description>
    <link>https://dev.to/leo_wong_12555ba8c901c8ce</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%2F4269066%2F2123bef5-2cc9-4dff-9611-7691bde96133.png</url>
      <title>DEV Community: Leo Wong</title>
      <link>https://dev.to/leo_wong_12555ba8c901c8ce</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/leo_wong_12555ba8c901c8ce"/>
    <language>en</language>
    <item>
      <title>Morse code in 2026: four places it still shows up, and how to encode it correctly</title>
      <dc:creator>Leo Wong</dc:creator>
      <pubDate>Sat, 28 Nov 2026 05:52:22 +0000</pubDate>
      <link>https://dev.to/leo_wong_12555ba8c901c8ce/morse-code-in-2026-four-places-it-still-shows-up-and-how-to-encode-it-correctly-29m7</link>
      <guid>https://dev.to/leo_wong_12555ba8c901c8ce/morse-code-in-2026-four-places-it-still-shows-up-and-how-to-encode-it-correctly-29m7</guid>
      <description>&lt;p&gt;Morse code is not dead. It is just no longer a communication standard, which means most of the code you see today is either deliberately minimal or quietly load-bearing. Here are the four places I keep running into it, and the timing rules that decide whether your encoder produces something a human can actually read.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Aviation and marine identifiers
&lt;/h2&gt;

&lt;p&gt;Navigation beacons still carry short Morse identifiers so a receiver can confirm which station it is hearing without demodulating anything else. Signal lamps between vessels are the same idea in a different medium. Nobody transmits sentences; they transmit an ident, once per cycle, forever.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Amateur radio
&lt;/h2&gt;

&lt;p&gt;This is the one place where full Morse conversation survived. Calling CQ, contest exchanges, straight keys and paddles, and a whole ecosystem of software keyers. It is also where the timing standards matter most, because operators read by ear and a sloppy element gap turns into a different character.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Accessibility and single-switch input
&lt;/h2&gt;

&lt;p&gt;Morse is one of the cheapest input methods that exists: one or two switches, no keyboard. Used with sip-and-puff or head switches, it gives full text entry to people for whom a standard keyboard is not an option. That constraint is why it keeps turning up in assistive tech discussions decades after the telegraph.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Puzzles, escape rooms and geocaching
&lt;/h2&gt;

&lt;p&gt;Designers like it because it is visually opaque to most players and trivially decodable once you spot it. The failure mode is always the same: the puzzle uses a nonstandard separator and the player cannot tell where one letter ends.&lt;/p&gt;

&lt;h2&gt;
  
  
  The timing rules people get wrong
&lt;/h2&gt;

&lt;p&gt;Everything in Morse is measured in one unit, usually called a dot length:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;dot = 1 unit&lt;/li&gt;
&lt;li&gt;dash = 3 units&lt;/li&gt;
&lt;li&gt;gap between elements of the same character = 1 unit&lt;/li&gt;
&lt;li&gt;gap between characters = 3 units&lt;/li&gt;
&lt;li&gt;gap between words = 7 units&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Three mistakes account for most unreadable output:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Equal spacing everywhere.&lt;/strong&gt; If the intra-character and inter-character gaps are the same, &lt;code&gt;S&lt;/code&gt; and &lt;code&gt;EEE&lt;/code&gt; become the same string.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dashes that are not three times a dot.&lt;/strong&gt; Reading by ear, a 2-unit dash is ambiguous.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No word gap.&lt;/strong&gt; Text without the 7-unit gap reads as one long stream and slows decoding to a crawl.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  A practical check
&lt;/h2&gt;

&lt;p&gt;If you are writing an encoder, the cheapest test is to round-trip: encode a paragraph, decode it back, and compare. A tool that does both directions is enough for that loop - I use &lt;a href="https://morse-code-translator.org/" rel="noopener noreferrer"&gt;https://morse-code-translator.org/&lt;/a&gt; because it does encode and decode on the same page without an account, which makes the round-trip a two-second check rather than a project.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why it still matters
&lt;/h2&gt;

&lt;p&gt;Not because anyone needs to send a telegram. Because Morse is the smallest possible encoding of an alphabet, and small encodings are exactly what you want when the input device is one switch, one light, or one hand. The rules above are the whole language: get the timing right and it works anywhere.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>beginners</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Image-to-image editing in the browser: what actually changes when you type a prompt</title>
      <dc:creator>Leo Wong</dc:creator>
      <pubDate>Fri, 27 Nov 2026 13:27:51 +0000</pubDate>
      <link>https://dev.to/leo_wong_12555ba8c901c8ce/image-to-image-editing-in-the-browser-what-actually-changes-when-you-type-a-prompt-524n</link>
      <guid>https://dev.to/leo_wong_12555ba8c901c8ce/image-to-image-editing-in-the-browser-what-actually-changes-when-you-type-a-prompt-524n</guid>
      <description>&lt;p&gt;Most people meet image generation as text-to-image: type a scene, get a picture that never existed. Image-to-image is the other half of that story, and it is the half that fits real work, because you start from a photo you already have.&lt;/p&gt;

&lt;p&gt;Here is what I have learned using i2i for product shots, thumbnails and blog images over the last year.&lt;/p&gt;

&lt;h2&gt;
  
  
  What i2i keeps, and what it replaces
&lt;/h2&gt;

&lt;p&gt;In text-to-image the model invents everything. In image-to-image the source photo is a constraint: composition, perspective and usually the identity of the main subject survive, while the attributes you describe get rewritten. That sounds simple, but it is the whole reason i2i is usable for real assets - the guardrails are the photo itself.&lt;/p&gt;

&lt;p&gt;The practical consequence: &lt;strong&gt;describe changes, not scenes&lt;/strong&gt;. If you write a full scene description, the model has to reconcile it with the source and you get mush.&lt;/p&gt;

&lt;h2&gt;
  
  
  Three prompt patterns that work
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;1. Background swap.&lt;/strong&gt; Keep the subject, name the new environment and the light: &lt;em&gt;“replace the background with a plain warm grey studio wall, soft window light from the left, keep the product untouched”&lt;/em&gt;. Naming the light matters more than naming the color.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Style transfer.&lt;/strong&gt; Anchor on one reference: &lt;em&gt;“repaint this as a flat vector illustration, three colors, no gradients, thick outlines”&lt;/em&gt;. Two style adjectives fight each other; one style plus concrete attributes does not.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Object replacement.&lt;/strong&gt; Say what leaves, what arrives, and what must not move: &lt;em&gt;“remove the coffee cup, put a folded notebook in the same spot, keep the desk position and shadows”&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Failure modes worth knowing
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Identity drift.&lt;/strong&gt; Faces and logos drift when the edit touches them at all. Mask the area you care about or run the pass and composite the untouched region back.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Text mangling.&lt;/strong&gt; Small type in the source becomes plausible-looking nonsense. Regenerate type in a design tool instead.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Over-stylization.&lt;/strong&gt; A model asked for “a bit more contrast” will often return a different image. Ask for a specific operation instead of a vague intensity.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hands and thin structures.&lt;/strong&gt; Straps, cables, glasses frames: any edit near them tends to melt.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  One change per pass
&lt;/h2&gt;

&lt;p&gt;Stacking three edits in one prompt is where quality falls off a cliff. I run one change at a time and keep the source and each intermediate result, so a failed pass costs one step and not the whole session. The same rule applies whether I am working in a desktop app or in a browser tool - the pass count is the variable.&lt;/p&gt;

&lt;p&gt;When I want a fast first pass without opening Photoshop, I run the photo through imgtoimg AI (&lt;a href="https://imgtoimg-ai.net/" rel="noopener noreferrer"&gt;https://imgtoimg-ai.net/&lt;/a&gt;), a browser-based image-to-image editor: upload the file, type the change, download the result. No install, and a few edits a day are free, which is enough for a thumbnail pass.&lt;/p&gt;

&lt;h2&gt;
  
  
  When not to use it
&lt;/h2&gt;

&lt;p&gt;For exact color matching, layered retouching or anything that has to be reproducible pixel-for-pixel, stay in a deterministic editor. i2i is for the exploration step - the ten variations you look at before deciding what the final asset should be. Used that way it saves real time; used as a replacement for retouching, it creates work.&lt;/p&gt;

&lt;h2&gt;
  
  
  The short version
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Start from the photo; describe the delta.&lt;/li&gt;
&lt;li&gt;One change per pass, and keep every intermediate.&lt;/li&gt;
&lt;li&gt;Protect faces, logos and fine structures.&lt;/li&gt;
&lt;li&gt;Treat output as a candidate, not a deliverable.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
