-
Notifications
You must be signed in to change notification settings - Fork 994
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:redwoodjs/redwood into feat/dc-rc-o…
…g-gen-mw-p2 * 'main' of github.com:redwoodjs/redwood: fix(deps): update React to latest canary 19.x (#10496) fix(upgrade): Download yarn patches (#10497) Revert React 19 upgrade (#10482 and #10491) (#10495) Modified type for describeScenario (#10468) fix(upgrade): Download yarn patches (#10491) fix(deps): update React to latest canary 19.x (#10482) chore(dataMigrate): Fix package.json directory value (#10490) RSC: css preinit: Add required option precedence (#10481) chore(renovate): Remove config for unused package (#10489) RSC: Update test projects to use new @apollo/client-react-streaming (#10488) RSC: Remove unused vite patch from test-project-rsa (#10487) chore(ssr): Switch to use `@apollo/client-react-streaming` package (#10484) chore(docs): Move .mdx import into separate file (#10486) fix(cli): avoid `npx` during upgrade command (#10479) fix: Fixes Unknown Fragment issues due to GraphQL Tag type mismatch in web (#10357) RSC: Clean up some comments and logs (#10480) feat: redwoodjs/auth-dbauth-middleware - Part 2/3 - Auth Middleware for dbAuth to authenticate users via cookie (#10447)
- Loading branch information
Showing
57 changed files
with
1,084 additions
and
198 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
- feat(auth): redwoodjs/auth-dbauth-middleware - Auth Middleware for dbAuth to authenticate users via cookie | ||
|
||
* Implements createDbAuthMiddleware in @redwoodjs/auth-dbauth-middleware:build | ||
* Used to register middleware for dbAuth in RedwoodJS projects |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
- fix(cli): avoid `npx` during upgrade command (#10479) by @Josh-Walker-GM | ||
|
||
This change fixes a problem with the `yarn rw upgrade` command when you don't have `npx` installed. If you don't have `npx` installed you will now have to manually run a command to dedupe dependencies rather than this being done for you automatically during the upgrade command. If this is the case, the `npx` command will be logged to the console when you run `yarn rw upgrade`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
- PR title (#PR number) by @PR author | ||
|
||
fix: Fixes Unknown Fragment issues due to GraphQL Tag type mismatch in web (#10357) by @dthyresson | ||
|
||
Users reported in #10322 an incompatibility with fragments and when using gql from global web. The TS errors were caused by the global web gql type not being compatible with the standard graphql-tag type. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,6 +37,7 @@ | |
"redwoodjs", | ||
"rsdw", | ||
"RWJS", | ||
"superjson", | ||
"tailwindcss", | ||
"waku" | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 0 additions & 19 deletions
19
__fixtures__/test-project-rsa/.yarn/patches/vite-npm-4.4.9-e845c1bbf8.patch
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
'use client' | ||
|
||
import ReactPlayer from 'react-player' | ||
|
||
export default ReactPlayer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# DbAuth Middleware | ||
|
||
|
||
```tsx filename='entry.server.tsx' | ||
import type { TagDescriptor } from '@redwoodjs/web' | ||
|
||
import App from './App' | ||
import { createDbAuthMiddleware } from '@redwoodjs/auth-dbauth-middleware' | ||
import { Document } from './Document' | ||
|
||
// eslint-disable-next-line no-restricted-imports | ||
import { handler as dbAuthHandler } from '$api/src/functions/auth' | ||
import { cookieName } from '$api/src/lib/auth' | ||
import { getCurrentUser } from '$api/src/lib/auth' | ||
interface Props { | ||
css: string[] | ||
meta?: TagDescriptor[] | ||
} | ||
|
||
export const registerMiddleware = () => { | ||
const dbAuthMiddleware = createDbAuthMiddleware({ | ||
cookieName, | ||
dbAuthHandler, | ||
getCurrentUser, | ||
// dbAuthUrl? optional | ||
}) | ||
return [dbAuthMiddleware] | ||
} | ||
|
||
export const ServerEntry: React.FC<Props> = ({ css, meta }) => { | ||
return ( | ||
<Document css={css} meta={meta}> | ||
<App /> | ||
</Document> | ||
) | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { build } from '@redwoodjs/framework-tools' | ||
|
||
await build() |
4 changes: 4 additions & 0 deletions
4
packages/auth-providers/dbAuth/middleware/cjsWrappers/plugin.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* eslint-env node */ | ||
|
||
module.exports = | ||
require('../dist/vite-plugin-auth-dbauth-middleware.js').default |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
{ | ||
"name": "@redwoodjs/auth-dbauth-middleware", | ||
"version": "7.0.0", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/redwoodjs/redwood.git", | ||
"directory": "packages/auth-providers/dbAuth/middleware" | ||
}, | ||
"license": "MIT", | ||
"exports": { | ||
".": { | ||
"default": "./dist/index.js" | ||
}, | ||
"./plugin": { | ||
"import": "./dist/vite-plugin-auth-dbauth-middleware.js", | ||
"default": "./cjsWrappers/plugin.js" | ||
} | ||
}, | ||
"main": "./dist/index.js", | ||
"types": "./dist/index.d.ts", | ||
"files": [ | ||
"dist", | ||
"cjsWrappers" | ||
], | ||
"scripts": { | ||
"build": "tsx ./build.mts && yarn build:types", | ||
"build:pack": "yarn pack -o redwoodjs-auth-dbauth-middleware.tgz", | ||
"build:types": "tsc --build --verbose", | ||
"prepublishOnly": "NODE_ENV=production yarn build", | ||
"test": "vitest run", | ||
"test:watch": "vitest watch" | ||
}, | ||
"dependencies": { | ||
"@redwoodjs/auth-dbauth-api": "workspace:*" | ||
}, | ||
"devDependencies": { | ||
"@redwoodjs/api": "workspace:*", | ||
"@redwoodjs/framework-tools": "workspace:*", | ||
"@redwoodjs/graphql-server": "workspace:*", | ||
"@redwoodjs/vite": "workspace:*", | ||
"@types/aws-lambda": "8.10.136", | ||
"ts-toolbelt": "9.6.0", | ||
"tsx": "4.7.1", | ||
"typescript": "5.4.5", | ||
"vitest": "1.4.0" | ||
}, | ||
"gitHead": "3905ed045508b861b495f8d5630d76c7a157d8f1" | ||
} |
Oops, something went wrong.