Skip to content

Commit a8d7f39

Browse files
committed
doc cors requeriments
1 parent 4a2dcad commit a8d7f39

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ SPA or SSR, including login, password reset, and more.
1616
- [Customize](#customize)
1717
- [More info](#more-info)
1818

19-
2019
## Installation
2120

2221
```bash
@@ -44,7 +43,15 @@ Add Sanctum's middleware to your api middleware group within your application's
4443
],
4544
```
4645

47-
Setting the `supports_credentials` option within your application's `config/cors.php` configuration file to `true`.
46+
Configure cors, you need edit the file `config/cors.php` and change this lines:
47+
48+
```php
49+
'paths' => ['api/*', 'sanctum/csrf-cookie', 'login', 'logout', 'password/forget', 'password/reset'],
50+
51+
/// ...
52+
53+
'supports_credentials' => true,
54+
```
4855

4956
In production define this environment variables:
5057

0 commit comments

Comments
 (0)