<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Rest on JsonKit Blog</title>
    <link>https://jsokit.com/blog/tags/rest/</link>
    <description>Recent content in Rest on JsonKit Blog</description>
    <generator>Hugo</generator>
    <language>en</language>
    <copyright>© 2025 JsonKit</copyright>
    <lastBuildDate>Thu, 07 May 2026 14:22:41 +0000</lastBuildDate>
    <atom:link href="https://jsokit.com/blog/tags/rest/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Building a Text Replace Tool: Regex and String Processing</title>
      <link>https://jsokit.com/blog/posts/building-a-text-replace-tool-regex-and-string-processing/</link>
      <pubDate>Thu, 07 May 2026 14:22:41 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/building-a-text-replace-tool-regex-and-string-processing/</guid>
      <description>Building a Text Replace Tool: Regex and String Processing Recently, I needed to implement a batch replace feature supporting both plain text and regex modes. Seemed simple, but I ran into some interesting gotchas. Here&amp;rsquo;s what I learned.&#xA;Core Requirements A text replace tool typically needs:&#xA;Plain text replace: Direct string search and replace Regex replace: Pattern matching with regular expressions Case sensitivity: Respect or ignore case Replace all vs. first: Replace all matches or just the first one The Plain Text Trap The simplest approach is String.</description>
    </item>
    <item>
      <title>REST API Documentation Generator: From Manual Maintenance to One-Click Automation</title>
      <link>https://jsokit.com/blog/posts/rest-api-documentation-generator-from-manual-maintenance-to-one-click-automation/</link>
      <pubDate>Wed, 29 Apr 2026 17:07:25 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/rest-api-documentation-generator-from-manual-maintenance-to-one-click-automation/</guid>
      <description>REST API Documentation Generator: From Manual Maintenance to One-Click Automation Every backend developer knows this pain: the API changed but the docs didn&amp;rsquo;t; new team members stare at outdated documentation in confusion; during integration, parameter descriptions turn out to be the exact opposite of actual behavior. Manually maintaining API docs is not only time-consuming—it&amp;rsquo;s inherently prone to drifting out of sync with the code.&#xA;Let&amp;rsquo;s talk about how a REST API documentation generator solves this problem, and dive into the technical implementation details.</description>
    </item>
    <item>
      <title>Responsive Testing Tool: iframe Sandbox and Device Simulation</title>
      <link>https://jsokit.com/blog/posts/responsive-testing-tool-iframe-sandbox-and-device-simulation/</link>
      <pubDate>Wed, 29 Apr 2026 12:44:26 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/responsive-testing-tool-iframe-sandbox-and-device-simulation/</guid>
      <description>Responsive Testing Tool: iframe Sandbox and Device Simulation Testing responsive designs usually means switching devices in Chrome DevTools or opening multiple tabs. I built a responsive testing tool that consolidates common device sizes with one-click switching and real-time preview.&#xA;iframe Sandbox: Loading External Pages Securely The core is using iframe to load target websites, but direct embedding has security restrictions:&#xA;&amp;lt;iframe src=&amp;#34;https://example.com&amp;#34; sandbox=&amp;#34;allow-scripts allow-same-origin allow-forms allow-popups&amp;#34; /&amp;gt; The sandbox attribute is critical:</description>
    </item>
    <item>
      <title>Linux pwd Command: From System Calls to Symbolic Link Handling</title>
      <link>https://jsokit.com/blog/posts/linux-pwd-command-from-system-calls-to-symbolic-link-handling/</link>
      <pubDate>Sun, 29 Mar 2026 11:53:43 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/linux-pwd-command-from-system-calls-to-symbolic-link-handling/</guid>
      <description>Linux pwd Command: From System Calls to Symbolic Link Handling The pwd command might be one of the simplest yet most frequently used Linux commands. But beneath its simplicity lies interesting implementation details and symbolic link handling logic that can save you from subtle scripting bugs.&#xA;Core Implementation: The getcwd() System Call At its core, pwd invokes the getcwd() system call, which returns the absolute path of the current process&amp;rsquo;s working directory.</description>
    </item>
    <item>
      <title>Linux du Command Deep Dive: From Disk Usage Statistics to Directory Space Analysis</title>
      <link>https://jsokit.com/blog/posts/linux-du-command-deep-dive-from-disk-usage-statistics-to-directory-space-analysis/</link>
      <pubDate>Wed, 18 Mar 2026 11:26:23 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/linux-du-command-deep-dive-from-disk-usage-statistics-to-directory-space-analysis/</guid>
      <description>Linux du Command Deep Dive: From Disk Usage Statistics to Directory Space Analysis Last week, our server triggered a disk space alert. I needed to quickly identify which directories were consuming the most space. I used to rely on ls -lh for a quick glance, but with deep directory structures, that approach is inefficient. This time I dug into the du command and discovered its design is more interesting than I thought.</description>
    </item>
    <item>
      <title>Linux diff Command: From Line-by-Line Comparison to Unified Format</title>
      <link>https://jsokit.com/blog/posts/linux-diff-command-from-line-by-line-comparison-to-unified-format/</link>
      <pubDate>Tue, 17 Mar 2026 11:57:52 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/linux-diff-command-from-line-by-line-comparison-to-unified-format/</guid>
      <description>Linux diff Command: From Line-by-Line Comparison to Unified Format During a recent code review, I needed to compare two config files. Staring at them side-by-side was painful. Then I remembered diff — a tool I&amp;rsquo;d used countless times but never really understood. Turns out, its implementation is more interesting than I expected.&#xA;The Core Algorithm: LCS (Longest Common Subsequence) The essence of diff is finding the minimum set of differences between two files.</description>
    </item>
    <item>
      <title>Canvas Image Pixelation: The Two-Step Scale Down and Scale Up Approach</title>
      <link>https://jsokit.com/blog/posts/canvas-image-pixelation-the-two-step-scale-down-and-scale-up-approach/</link>
      <pubDate>Mon, 23 Feb 2026 19:55:42 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/canvas-image-pixelation-the-two-step-scale-down-and-scale-up-approach/</guid>
      <description>Canvas Image Pixelation: The Two-Step Scale Down and Scale Up Approach Recently, while building an image pixelation tool, I discovered something interesting: many implementations manually iterate through each pixel block to calculate average colors. That works, but there&amp;rsquo;s a more elegant approach—leveraging Canvas scaling behavior.&#xA;What is Pixelation? Pixelation is an image processing technique that reduces resolution to hide details. Essentially, you divide an image into blocks and fill each block with a single color.</description>
    </item>
    <item>
      <title>Building a GIF Maker from Scratch: LZW Compression and Median Cut Color Quantization</title>
      <link>https://jsokit.com/blog/posts/building-a-gif-maker-from-scratch-lzw-compression-and-median-cut-color-quantization/</link>
      <pubDate>Fri, 13 Feb 2026 17:56:05 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/building-a-gif-maker-from-scratch-lzw-compression-and-median-cut-color-quantization/</guid>
      <description>Building a GIF Maker from Scratch: LZW Compression and Median Cut Color Quantization Written: 2026-04-30 12:39&#xA;Recently I added a GIF maker to JsonKit. I initially thought I&amp;rsquo;d just use an existing library, but implementing it from scratch turned out to be more interesting. This article explores the core technologies behind the GIF format: LZW compression and Median Cut color quantization.&#xA;Why is GIF So Tricky? The GIF format was born in 1987, and its design philosophy is completely different from modern formats.</description>
    </item>
    <item>
      <title>Extracting Color Palettes from Images: A Practical Guide to Color Quantization</title>
      <link>https://jsokit.com/blog/posts/extracting-color-palettes-from-images-a-practical-guide-to-color-quantization/</link>
      <pubDate>Sun, 01 Feb 2026 13:38:03 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/extracting-color-palettes-from-images-a-practical-guide-to-color-quantization/</guid>
      <description>Extracting Color Palettes from Images: A Practical Guide to Color Quantization I was building a design tool recently that needed to extract dominant colors from user-uploaded images. After diving into color quantization algorithms, I found it more interesting than expected.&#xA;The Core Problem A 1920×1080 image has 2 million pixels, each with its own RGB color. Direct counting could yield hundreds of thousands of unique colors—not very useful.&#xA;What we need: Find the 8-10 most representative colors from hundreds of thousands.</description>
    </item>
    <item>
      <title>The Encoding Principles Behind Barcodes: Building an Online Barcode Generator</title>
      <link>https://jsokit.com/blog/posts/the-encoding-principles-behind-barcodes-building-an-online-barcode-generator/</link>
      <pubDate>Sat, 24 Jan 2026 12:32:47 +0000</pubDate>
      <guid>https://jsokit.com/blog/posts/the-encoding-principles-behind-barcodes-building-an-online-barcode-generator/</guid>
      <description>The Encoding Principles Behind Barcodes: Building an Online Barcode Generator Recently added a barcode generation feature to a project. Turns out those black-and-white stripes have some interesting encoding rules underneath.&#xA;What is a Barcode? A barcode converts numbers or letters into alternating black and white stripes. When a scanner reads it, black bars absorb light while white spaces reflect it, generating electrical signals that decode back to the original content.</description>
    </item>
  </channel>
</rss>
