saritasa-nest / saritasa-dotnet-tools

Development Tools For Company'S .NET Projects.
BSD 2-Clause "Simplified" License
27 stars 13 forks source link

Simplify Empty Paginations and Creation #63

Closed krasninja closed 5 years ago

krasninja commented 5 years ago

To create empty PagedList we need to use this code:

return PagedListFactory.AsOnePage(Enumerable.Empty<ImageDto>().ToList());

Can we simplify usage with shorthand like this?

PagedListFactory.Empty<ImageDto>();

Also creating PagedList requires to provide type argument explicitly, can we have any shorthand to simplify class creation.

PS Right now lists do not suppor serialization.

krasninja commented 5 years ago

Fixed in 2.0.0