You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For greater flexibility and improved consistency with other Astro code, session drivers are now specified as an object:
11
+
12
+
```diff
13
+
-import { defineConfig } from 'astro/config'
14
+
+import { defineConfig, sessionDrivers } from 'astro/config'
15
+
16
+
export default defineConfig({
17
+
session: {
18
+
- driver: 'redis',
19
+
- options: {
20
+
- url: process.env.REDIS_URL
21
+
- },
22
+
+ driver: sessionDrivers.redis({
23
+
+ url: process.env.REDIS_URL
24
+
+ }),
25
+
}
26
+
})
27
+
```
28
+
29
+
Specifying the session driver as a string has been deprecated, but will continue to work until this feature is removed completely in a future major version. The object shape is the current recommended and documented way to configure a session driver.
0 commit comments