Table of Contents

Class BrowserCookieAccess

Namespace
Dmnk.Blazor.Cookies
Assembly
Dmnk.Blazor.Cookies.dll

Allows direct access to cookie values through js interop

public static class BrowserCookieAccess
Inheritance
BrowserCookieAccess
Inherited Members

Methods

GetCookieValue(IJSRuntime, string, CancellationToken)

Get the value (and only the value, not the expiration date etc.) of a cookie by its name. Returns null if the cookie is not found.

public static ValueTask<string?> GetCookieValue(IJSRuntime js, string name, CancellationToken ct = default)

Parameters

js IJSRuntime
name string
ct CancellationToken

Returns

ValueTask<string>