Esempio n. 1
0
        private async Task LoadPokemon()
        {
            if (_IsVisibleAllPokemon)
            {
                var result = await _pokemonService.GetPokemonAsync(_restClient, _nextPage);

                if (string.IsNullOrEmpty(_nextPage))
                {
                    Pokemons.Clear();
                    Pokemons.AddRange(result.Results);
                }
                else
                {
                    Pokemons.AddRange(result.Results);
                }

                _nextPage = result.Next;
                SetTitleAll();
            }
        }