mirror of
https://github.com/xtr-dev/payload-feature-flags.git
synced 2025-12-10 02:43:25 +00:00
v0.0.14: Improve SSR support and fix race condition
Addresses critical issues identified in code review: 1. Server-Side Environment Handling: - Add warning when serverURL is not provided in SSR/SSG environments - Falls back to relative URLs with console warning - Prevents silent failures in server-side rendering 2. Race Condition Fix: - Use useRef for initialFlags to prevent re-creating fetchFlags on every render - Removes initialFlags from useCallback dependencies - Prevents excessive re-renders and potential infinite loops These improvements ensure better stability and reliability in both client-side and server-side environments. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@xtr-dev/payload-feature-flags",
|
||||
"version": "0.0.13",
|
||||
"version": "0.0.14",
|
||||
"description": "Feature flags plugin for Payload CMS - manage feature toggles, A/B tests, and gradual rollouts",
|
||||
"license": "MIT",
|
||||
"type": "module",
|
||||
|
||||
Reference in New Issue
Block a user