w(await _jsRuntime.InvokeAsync&lt;IJSObjectReference&gt;("import", "/js/IndexedDbAccessor.js"));
        }
    }

    public async ValueTask DisposeAsync()
    {
        if (_accessorJsRef.IsValueCreated)
        {
            await _accessorJsRef.Value.DisposeAsync();
        }
    }
}</pre>
<ol start="3">
    <li>Register the <code>IndexedDbAccessor&nbsp;</code>class in the <strong>Program.cs</strong> file:</li>
</ol>
<pre class="code" language="csharp">builder.Services.AddScoped&lt;IndexedDbAccessor&gt;(