Skip to content

Instantly share code, notes, and snippets.

@inherits ComponentBase
@inject IJSRuntime JSRuntime
<div class="modal" tabindex="-1" role="dialog" id="@Id" @attributes="Attributes">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">@Title</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">×</span>
using System;
using System.Runtime.Serialization;
namespace blazor
{
[Serializable]
internal class ComponentRefMissingException : InvalidOperationException
{
public ComponentRefMissingException(string componentName)
: base($"The component '{componentName}' is missing the '@ref' attribute.")