Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version Packages #1550

Merged
merged 1 commit into from
Sep 6, 2023
Merged

Version Packages #1550

merged 1 commit into from
Sep 6, 2023

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Aug 24, 2023

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to canary, this PR will be updated.

Releases

@faustwp/experimental-app-router@0.0.3

Patch Changes

  • a1b6fc0: Introduced a new API handler for App router projects called faustRouteHandler. It can be used by creating a file /app/api/faust/[route]/route.js with the following contents:

    // /app/api/faust/[route]/route.js
    import { faustRouteHandler } from '@faustwp/experimental-app-router';
    
    const { GET, POST } = faustRouteHandler;
    
    export { GET, POST };
  • a1b6fc0: Created getAuthClient for making authenticated server side requests in the Next.js App Router. It can be used like:

    import { getAuthClient } from '@faustwp/experimental-app-router';
    
    // app/my-account/posts/page.js
    export default async function Page() {
      const client = await getAuthClient();
    
      if (!client) {
        return <>You must be authenticated to view this page!</>;
      }
    
      const { data } = await client.query({
        query: gql`
          query GetMyPosts {
            viewer {
              posts {
                nodes {
                  id
                  title
                }
              }
            }
          }
        `,
      });
    
      return(
        <>
          <h2>My posts</h2>
           <ul>
            {data.viewer.posts.nodes.map((post) => (
              <li key={post.id}>{post.title}</li>
            ))}
          </ul>
        </>
      )

    Note: Our login/logout utils are still in the works.

  • Updated dependencies [a419252]

  • Updated dependencies [cf887d3]

  • Updated dependencies [795d956]

    • @faustwp/core@1.1.2

@faustwp/core@1.1.2

Patch Changes

  • a419252: Fixed an issue where persisted queries were not being enabled properly when setting the usePersistedQueries flag.

  • cf887d3: Fixed bug where the "Edit Post" link was missing in the Faust Toolbar

  • 795d956: Improved keyboard navigation within Toolbar menus, allowing for dropdowns to be toggled open with "enter"

    Note that the ToolbarItem component no longer uses the prop handleClick, instead relying on pass-through props in order to separate the click event from the the key event.

    <ToolbarItem onKeyDown={handleKeyDown} onClick={handleClick}>
      Log Out
    </ToolbarItem>

@github-actions github-actions bot requested a review from a team as a code owner August 24, 2023 20:27
@github-actions github-actions bot force-pushed the changeset-release/canary branch 8 times, most recently from e96be2c to ad103d5 Compare September 1, 2023 14:40
@github-actions github-actions bot force-pushed the changeset-release/canary branch 2 times, most recently from a03811a to 3e3d42e Compare September 4, 2023 09:20
@blakewilson blakewilson merged commit 4a20f9b into canary Sep 6, 2023
@blakewilson blakewilson deleted the changeset-release/canary branch September 6, 2023 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant