No people found
51 | } 52 | ``` 53 | 54 | You can write this 55 | 56 | ``` 57 |No people found
67 |Sorry, there's nothing at this address.
9 |Current count: @currentCount
6 | 7 | 8 | 9 | @code { 10 | private int currentCount = 0; 11 | 12 | private void IncrementCount() 13 | { 14 | currentCount++; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Source/Tutorials/ForEachExample/Pages/Error.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | 3 | 4 |9 | Swapping to Development environment will display more detailed information about the error that occurred. 10 |
11 |12 | The Development environment shouldn't be enabled for deployed applications. 13 | It can result in displaying sensitive information from exceptions to end users. 14 | For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development 15 | and restarting the app. 16 |
17 | -------------------------------------------------------------------------------- /Source/Tutorials/ForEachExample/Pages/FetchData.razor: -------------------------------------------------------------------------------- 1 | @page "/fetchdata" 2 | 3 | @using ForEachExample.Data 4 | @inject WeatherForecastService ForecastService 5 | 6 |This component demonstrates fetching data from a service.
9 | 10 |Loading...
13 |Date | 19 |Temp. (C) | 20 |Temp. (F) | 21 |Summary | 22 |
---|---|---|---|
@forecast.Date.ToShortDateString() | 28 |@forecast.TemperatureC | 29 |@forecast.TemperatureF | 30 |@forecast.Summary | 31 |
Index | 40 |Date | 41 |Temp. (C) | 42 |Temp. (F) | 43 |Summary | 44 |
---|---|---|---|---|
@item.Index | 50 |@item.Value.Date.ToShortDateString() | 51 |@item.Value.TemperatureC | 52 |@item.Value.TemperatureF | 53 |@item.Value.Summary | 54 |