public Task <IJSObjectReference> GetJSModule(string jsPath, string?assemblyName = null, CancellationToken cancellationToken = default) { if (assemblyName is null) { assemblyName = typeof(T).Assembly.GetName().Name ?? ""; } string id = $"{assemblyName}/{jsPath}"; if (!JSInvokers.ContainsKey(id)) { Logger.LogInformation($"Create JS invoker: {id}."); JSInvokers.Add(id, new(() => JSRuntime.InvokeAsync <IJSObjectReference>("import", cancellationToken, $"./_content/{id}").AsTask())); } return(JSInvokers[id].Value); }