clerk / javascript

Official Javascript repository for Clerk authentication
https://clerk.com
MIT License
981 stars 221 forks source link

chore(astro): Drop convenience Astro wrappers for React #3682

Closed wobsoriano closed 2 weeks ago

wobsoriano commented 2 weeks ago

Description

We have 3 ways of importing Astro/React Clerk components (docs WIP):

  1. import { } from '@clerk/astro/components/{control|interactive|unstyled}' - Fully Astro components.
  2. import { } from '@clerk/astro/client/react' - React components. Needs the client:load directive when imported in an Astro component to be hydrated.
  3. import { } from '@clerk/astro/components/react - Astro components that wrap option 2 with the client:load directive for convenience.

Multiple import methods can confuse users. Some features, like theasChild prop for unstyled components, don't work when React components are used in Astro due to Astro's slot system and islands architecture. As a result, we're discontinuing option 3.

Checklist

Type of change

changeset-bot[bot] commented 2 weeks ago

🦋 Changeset detected

Latest commit: 32032bc70c3dacce87608b17b430c09ef90257a9

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package | Name | Type | | ------------ | ----- | | @clerk/astro | Patch |

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR