auth-work

Implement Wix Member Features authentication with useMembers hook and route guarding.

Updated May 1, 2026
One-click install
npx skills add https://github.com/Rachit246-art/rvglobal1 --skill auth-work-rachit246-art
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: auth-work
Source: https://github.com/Rachit246-art/rvglobal1/tree/main/.emdash/skills/auth-work
Command: npx skills add https://github.com/Rachit246-art/rvglobal1 --skill auth-work-rachit246-art

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you implement authentication and member-only functionality without building unsafe or custom auth logic.

Core Features & Use Cases

  • Wix-powered authentication only: Enforces using Wix Member Features so authentication is managed by Wix rather than custom flows.
  • Member state handling: Provides the useMembers hook pattern to read loggedInMember/member, including profile fields and IDs.
  • Protected route patterns: Shows how to guard routes by redirecting unauthenticated users to /login, including loading/skeleton behavior and return URL preservation.
  • Auth-aware navigation & UI: Supports conditional rendering for logged-in vs logged-out states and a user menu approach driven by member data.
  • New user/profile edge cases: Handles cases where a newly registered user may not have saved profile data yet.

Quick Start

Use the auth-work skill to protect a page by redirecting to /login when loggedInMember?.id is missing, while preserving the original destination for post-login return.

Frequently Asked Questions about auth-work

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I protect routes in React and redirect unauthenticated users to login?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.

How do I handle conditional UI rendering for logged-in vs logged-out members?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.

Does Wix Members support custom auth flows and token handling for React?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.

Why does a newly registered user not have saved profile data on first login?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.

What is the best way to preserve return URLs when redirecting users to a login page?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.

Can I use the useMembers hook to show loading skeletons while checking auth state?

Wix-powered authentication manages member access using the `useMembers` hook to read `loggedInMember` data. It enforces Wix Member Features rather than custom flows, ensuring secure login/logout navigation and profile handling.