@page "/person/{Address}"
@Address
@if (bio == null)
{
Getting Bio...
}
else {
@bio
}
@if (statuses == null) {
Loading Statuses...
}
else {
@foreach (var status in statuses) {
}
}
@code {
[Parameter]
public string Address { get; set; }
private Status[]? statuses;
private MarkupString? bio;
protected override async Task OnInitializedAsync() {
RestService api = new RestService();
await GetBioAsync(api);
// GetStatusesAsync(api);
}
private async Task GetStatusesAsync(RestService api) {
statuses = (await api.Statuslog(Address)).ToArray();
}
private async Task GetBioAsync(RestService api) {
bio = await api.StatuslogBio(Address);
}
}