Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .changeset/five-lamps-beam.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
'gatsby-plugin-clerk': patch
'@clerk/clerk-js': patch
'@clerk/clerk-sdk-node': patch
'@clerk/backend': patch
'@clerk/nextjs': patch
'@clerk/remix': patch
---

Update README for v5
2 changes: 1 addition & 1 deletion packages/backend/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ This package provides Clerk Backend API resources and low-level authentication u
- Built for V8 isolates (Cloudflare Workers, Vercel Edge Runtime, etc...).
- Make it isomorphic to work across all modern JS runtimes.
- Use options injection for all keys and settings.
- Support multiple CLERK_API_KEY for multiple instance REST access.
- Support multiple `CLERK_SECRET_KEY` for multiple instance REST access.
- Align JWT key resolution algorithm across all environments (Function param > Environment variable > JWKS from API).
- Tested automatically across different runtimes (Node, CF Workers, Vercel Edge middleware.)
- Refactor the Rest Client API to return `{data, errors}` instead of throwing errors.
Expand Down
6 changes: 3 additions & 3 deletions packages/clerk-js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,22 +58,22 @@ await clerk.load({

### Install ClerkJS as script

ClerkJS can be loaded from a `<script />` tag with the source from your [Frontend API](https://dashboard.clerk.com/last-active?path=api-keys) URL.
ClerkJS can be loaded from a `<script />` tag with the source from your [Frontend API URL](https://dashboard.clerk.com/last-active?path=api-keys).

Add the following script to your site's `<body>` element:

```html
<script>
// Get this URL and Publishable Key from the Clerk Dashboard
const clerkPublishableKey = 'pk_[publishable_key]';
const frontendApi = '[your-domain].clerk.accounts.dev';
const frontendApiUrl = '[your-domain].clerk.accounts.dev';
const version = '@latest'; // Set to appropriate version

// Creates asynchronous script
const script = document.createElement('script');
script.setAttribute('data-clerk-publishable-key', clerkPublishableKey);
script.async = true;
script.src = `https://${frontendApi}/npm/@clerk/clerk-js${version}/dist/clerk.browser.js`;
script.src = `https://${frontendApiUrl}/npm/@clerk/clerk-js${version}/dist/clerk.browser.js`;

// Adds listener to initialize ClerkJS after it's loaded
script.addEventListener('load', async function () {
Expand Down
4 changes: 2 additions & 2 deletions packages/gatsby-plugin-clerk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,8 @@ Importing `'gatsby-plugin-clerk/api'` gives access to all the exports coming fro
import { clerkClient, withAuth } from 'gatsby-plugin-clerk/api';

const handler = withAuth(async (req, res) => {
const users = await clerkClient.users.getUserList();
res.send({ title: `We have ${users.length} users`, auth: req.auth });
const { totalCount } = await clerkClient.users.getUserList();
res.send({ title: `We have ${totalCount} users`, auth: req.auth });
});

export default handler;
Expand Down
3 changes: 2 additions & 1 deletion packages/nextjs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ and profile management to your application in minutes.

### Prerequisites

- Next.js v10+
- Next.js 13.0.4 or later
- React 18 or later
- Node.js `>=18.17.0` or later

### Installation
Expand Down
7 changes: 3 additions & 4 deletions packages/remix/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Clerk is the easiest way to add authentication and user management to your Remix
### Prerequisites

- Remix `^2.0.0` or later
- React 18 or later
- Node.js `>=18.17.0` or later

### Installation
Expand Down Expand Up @@ -73,15 +74,13 @@ You can get these from the [API Keys](https://dashboard.clerk.com/last-active?pa
To initialize Clerk with your Remix application, you will need to make three modifications to `app/root.jsx`:

1. Export `rootAuthLoader` as `loader`
2. Export `ClerkErrorBoundary` as `ErrorBoundary`
3. Wrap the default export with `ClerkApp`
1. Wrap the default export with `ClerkApp`

```jsx
import { rootAuthLoader } from '@clerk/remix/ssr.server';
import { ClerkApp, ClerkErrorBoundary } from '@clerk/remix';
import { ClerkApp } from '@clerk/remix';

export const loader = args => rootAuthLoader(args);
export const ErrorBoundary = ClerkErrorBoundary();

function App() {
return <html lang='en'>[...]</html>;
Expand Down
2 changes: 1 addition & 1 deletion packages/sdk-node/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ You will then be able to access all the available methods.
import 'dotenv/config'; // To read CLERK_SECRET_KEY
import clerk from '@clerk/clerk-sdk-node';

const userList = await clerk.users.getUserList();
const { data: userList } = await clerk.users.getUserList();
```

_For further details and examples, please refer to our [Documentation](https://clerk.com/docs/reference/node/getting-started?utm_source=github&utm_medium=clerk_sdk_node)._
Expand Down