r/reactjs • • May 06 '26

Show /r/reactjs I extracted the "frecency" pattern from Firefox/VS Code into a reusable library — your UI adapts to each user automatically

38 Upvotes

Every complex app has the same problem: 50 options in the sidebar, each user only uses 8-10. The rest is noise. Firefox solved this for the URL bar years ago using "frecency" (frequency + recency). VS Code does the same for the command palette. But nobody's packaged it as a reusable primitive.

So I did. 4.5KB, zero deps, framework-agnostic:

morph.track('sidebar', 'tasks') // on interaction

morph.rank('sidebar') // on page load — sorted by usage.

Items used often and recently score high. Items ignored fade naturally. All data stays in localStorage. No AI, no server, no "customize layout" button needed.

Live demo: https://morph-black.vercel.app/

Would you actually use this? Curious if people see this as useful or overkill for most apps.


r/reactjs • • May 07 '26

Needs Help Build once deploy many React Vite

2 Upvotes

Hi everyone,

I’m trying to achieve a true “build once, deploy many” setup for a React app built with Vite.

I currently have around 50 production environments/tenants and I want to avoid rebuilding the frontend separately for each one. The goal is to create a single Docker image/static frontend build and deploy the exact same artifact everywhere, while still being able to inject environment-specific values at runtime.

I already know that Vite replaces import.meta.env during build time, so I’m looking for production-proven approaches that allow runtime injection instead of build-time replacement.

I’d love to hear how people usually solve this in real-world setups, especially in multi-tenant SaaS systems or apps with many deployments.

What approaches are considered the cleanest and most maintainable today?
How are people handling runtime environment values with static React builds?
Are there any common pitfalls, scaling issues, caching/CDN problems, or deployment concerns I should be aware of?


r/reactjs • • May 07 '26

Resource I built an open source productivity workspace using Next.js 16, React 19, and Supabase.

Thumbnail
chronoa.vercel.app
0 Upvotes

I recently open sourced Chronoa. It is a fully synced workspace featuring task management, global timers, a markdown editor, and ICS calendar integration.

I wanted to focus heavily on performance and aesthetics. State syncs instantly across your phone and laptop using Supabase Realtime channels. The frontend is built with Next.js App Router and Tailwind CSS 4, while the backend utilizes Python and Flask for background cron jobs.

Live App: https://chronoa.vercel.app/
Source Code: https://github.com/XeCipher/Chronoa

Check out the code, and please star the repo if you find it helpful for your own learning or workflow.


r/reactjs • • May 07 '26

Show /r/reactjs Open source pixel art component library for React - feedback welcome!

3 Upvotes

Hey r/reactjs! 👾

I've been working on pixelartui-react - an open-source component library that brings pixel art aesthetics to React applications.

What it is

A collection of 11+ React components (Button, Modal, Select, TextInput, Pagination, Switch, etc.) all styled with authentic pixel art design. Perfect for retro-styled games, creative portfolios, or any project where you want to stand out from the typical Material UI look.

Quick example

npm install pixelartui-react

import { Button, Modal, TextInput } from 'pixelartui-react';

// That's it - you've got pixel perfect retro components

Why I built it

I was building a web-based retro game and realized I was spending more time crafting pixel-perfect borders and shadows than actually building game logic. So I extracted it into a reusable library that anyone can use.

Features

  • ⚡ Built for React 19
  • 📦 TypeScript support
  • 🎨 Customizable theming
  • 🌐 MIT licensed
  • 🎮 Perfect for game UIs, creative projects, and portfolios

Current state

  • Version 0.4.45 on npm
  • 4 GitHub stars (early days!)
  • ~10 weekly downloads
  • Active development

What's next

  • Deploying Storybook for interactive component demos
  • Adding more components (Tabs, Tooltips, Dropdowns)
  • Building a theme customizer tool
  • Growing the community

Links

Looking for

  • Feedback on the API and component design
  • Contributors who want to help build more components
  • Anyone who wants to try it in their projects
  • Stars if you find it interesting! ⭐

I'd love to hear your thoughts, suggestions, or questions. Have you built any retro-styled React apps? What components would you like to see added?

Thanks for checking it out!