How to Make 恋みくじ Results Shareable Without Storing Personal Data
This post explains one of the technical and privacy questions behind the project rather than presenting an independent review. A share button seems like a small feature. The visitor receives a result, presses “Share,” and sends it to a friend. From a product perspective, sharing can help an experience travel beyond its original website. But when the product involves personal emotions, the…
The concept of a 恋みくじ, or Japanese-style love fortune, involves personal emotions for the user, such as contemplating feelings, delayed replies, or relationship uncertainties. When sharing these results, it's crucial to ensure that personal data remains private. A share button, seemingly a simple feature, requires careful consideration of data boundaries to protect user privacy.
The architecture should separate data into three categories: public content, private context, and operational data. Public content includes the fortune result ID, published headline, interpretation, interface language, and product URL. Private context contains information like the visitor's name, romantic question, relationship history, and personal notes. Operational data may include page load count, draw completion, error information, and selected language.
A shareable result should be constructed solely from public content, not private context. The shared URL should not expose any private information. One implementation mistake is placing all interaction data within a query string, as this can leak sensitive information through browser history, server logs, screenshots, and links.
To share a result safely, construct a shareable object containing a title, summary, and public URL. This object should be created from published content, excluding any personal data. Use the Web Share API for a native sharing interface, copying the public URL to the clipboard if the API is unavailable. Display a confirmation message to ensure visitors understand the sharing action worked.
Lastly, update the page title and description for social previews, but avoid including personal details in the URL. By focusing on public content and using progressive enhancement techniques, the sharing process remains secure and private while still providing a personalized experience for the user.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.