Cloud Album
A private cloud photo album for overseas users, focused on backup, organization, and subscription-ready experiences.
A real product journey covering the iOS client, MinIO storage, overseas payments, and growth experiments.
Products
Small, useful products backed by the engineering notes on this site.
A private cloud photo album for overseas users, focused on backup, organization, and subscription-ready experiences.
A real product journey covering the iOS client, MinIO storage, overseas payments, and growth experiments.
Blog
typeof works well for primitives, but arrays, plain objects, and null require more specific checks. Object.prototype.toString.call exposes a useful built-in type tag.
UEditor's upload dialog sends a multipart request and expects a response in the editor's documented JSON format. The backend must match the field name and action used by the selected UEditor version.
CSS cannot truncate text by an exact number of Chinese characters, but it can hide content according to an element's width or number of lines.
JavaScript strings use UTF-16 code units. Characters in the Basic Multilingual Plane fit in one unit, while supplementary characters such as many emoji use a surrogate pair.
Binary floating-point values cannot represent many decimal fractions exactly. This is why expressions such as 0.1 + 0.2 do not produce an exact decimal 0.3. Financial, accounting, tax, pricing, and measurement code often needs decimal arithmetic with explicit precision and rounding.
MockMvc exercises Spring MVC request handling without starting a real HTTP server.
A browser can preview a file explicitly selected by the user without uploading it first. Validate the MIME type, size, and number of files before rendering the preview.
Java regular expressions are compiled into a Pattern and applied through a Matcher.
A discussion system usually needs to represent a top-level comment, its replies, and the user being replied to.
Reading a file line by line is appropriate for logs and other large text files because it avoids loading the complete file into memory. Always specify the character set and close streams reliably.