docs: updates for breaking changes (#9558)
- Update modules registration - Update `medusa-config.js` to `medusa-config.ts` - Update the out directory in the admin deployment guide - Update logger imports - Other fixes Note: will need to re-generate references afterwards Closes #9548
This commit is contained in:
@@ -18,8 +18,8 @@ The Emailpass auth provider is registered by default with the Auth Module.
|
||||
|
||||
If you want to pass options to the provider, add the provider to the `providers` option of the Auth Module:
|
||||
|
||||
```js title="medusa-config.js"
|
||||
const { Modules } = require("@medusajs/framework/utils")
|
||||
```ts title="medusa-config.ts"
|
||||
import { Modules } from "@medusajs/framework/utils"
|
||||
|
||||
// ...
|
||||
|
||||
|
||||
@@ -35,8 +35,8 @@ Learn about the authentication flow in [this guide](../../authentication-route/p
|
||||
|
||||
Add the module to the array of providers passed to the Auth Module:
|
||||
|
||||
```js title="medusa-config.js"
|
||||
const { Modules } = require("@medusajs/framework/utils")
|
||||
```ts title="medusa-config.ts"
|
||||
import { Modules } from "@medusajs/framework/utils"
|
||||
|
||||
// ...
|
||||
|
||||
|
||||
@@ -35,8 +35,8 @@ Learn about the authentication flow for third-party providers in [this guide](..
|
||||
|
||||
Add the module to the array of providers passed to the Auth Module:
|
||||
|
||||
```js title="medusa-config.js"
|
||||
const { Modules } = require("@medusajs/framework/utils")
|
||||
```ts title="medusa-config.ts"
|
||||
import { Modules } from "@medusajs/framework/utils"
|
||||
|
||||
// ...
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@ By default, users of all actor types can authenticate with all installed auth mo
|
||||
|
||||
To restrict the auth providers used for actor types, use the [authMethodsPerActor option](/references/medusa-config#http-authMethodsPerActor-1-3) in Medusa's configurations:
|
||||
|
||||
```js title="medusa-config.js"
|
||||
```ts title="medusa-config.ts"
|
||||
module.exports = defineConfig({
|
||||
projectConfig: {
|
||||
http: {
|
||||
|
||||
@@ -26,27 +26,29 @@ By default, the `emailpass` provider is registered to authenticate customers and
|
||||
|
||||
For example:
|
||||
|
||||
```js title="medusa-config.js"
|
||||
const { Modules } = require("@medusajs/framework/utils")
|
||||
```ts title="medusa-config.ts"
|
||||
import { Modules } from "@medusajs/framework/utils"
|
||||
|
||||
// ...
|
||||
|
||||
module.exports = defineConfig({
|
||||
// ...
|
||||
modules: {
|
||||
resolve: "@medusajs/medusa/auth",
|
||||
options: {
|
||||
providers: [
|
||||
{
|
||||
resolve: "@medusajs/medusa/auth-emailpass",
|
||||
id: "emailpass",
|
||||
options: {
|
||||
// provider options...
|
||||
modules: [
|
||||
{
|
||||
resolve: "@medusajs/auth",
|
||||
options: {
|
||||
providers: [
|
||||
{
|
||||
resolve: "@medusajs/auth-emailpass",
|
||||
id: "emailpass",
|
||||
options: {
|
||||
// provider options...
|
||||
},
|
||||
},
|
||||
},
|
||||
],
|
||||
],
|
||||
},
|
||||
},
|
||||
},
|
||||
]
|
||||
})
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user