Releases: dghubble/sessions
Releases · dghubble/sessions
v0.4.1
What's New
- Update Go module dependencies and add configure changelog generator
Contributions
- Use a centrally managed GitHub Workflow for go tests by @dghubble in #25
- Allow Go test Workflow to run on PRs by @dghubble in #27
- Tag v0.4.1 release and configure changelog generator by @dghubble in #29
Dependencies
- Bump github.com/gorilla/securecookie from 1.1.1 to 1.1.2 by @dependabot in #28
New Contributors
- @dependabot made their first contribution in #28
Full Changelog: v0.4.0...v0.4.1
v0.4.0
- Allow
Session
to store values with specified type (V
) (i.e. generics) (#21)Session
state is now amap[string]V
instead of amap[string]any
- Update
Set
,Get
, andGetOk
methods to use generic typeV
- Change
Session
toSession[V any]
to specify the type of value stored in the Session - See updated usage docs for examples
- Change
Store
toStore[V any]
to specify the type of value stored in sessions - Change
NewCookieStore
toNewCookieStore[V any]
to specify the type of value stored in sessions
v0.3.1
v0.3.0
- Change
CookieStore
and its fields to be non-exported (#19)- Change
NewCookieStore
to require a*CookieConfig
and return aStore
- Rename
Config
struct toCookieConfig
- Add
DefaultCookieConfig
andDebugCookieConfig
convenience variables
- Change
- Change the
Session
fieldValues
to be non-exported (#18)- Add
Session
Set
method to set a key/value pair - Add
Session
Get
method to get a value for a given key - Add
Session
GetOk
to get a value for a given key and whether the key exists in the map
- Add
- Remove cookie
Config
field fromSession
(#17) - Add examples and project logo to README