Skip to content

Commit

Permalink
Update readme. Update package version.
Browse files Browse the repository at this point in the history
  • Loading branch information
a-gubskiy committed May 14, 2017
1 parent 747135d commit 411c7b0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
13 changes: 12 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,22 @@ PagedList is a library that enables you to easily take an IEnumerable/IQueryable

## How do I use it?

1. Install ["X.PagedList.Mvc"](http://nuget.org/List/Packages/X.PagedList.Mvc) via [NuGet](http://nuget.org) - that will automatically install ["X.PagedList"](https://nuget.org/packages/X.PagedList/) as well.
### Classic .NET (version 4.5.2 version and above)

Install ["X.PagedList.Mvc"](http://nuget.org/List/Packages/X.PagedList.Mvc) via [NuGet](http://nuget.org) - that will automatically install ["X.PagedList"](https://nuget.org/packages/X.PagedList/) as well.

### .NET Core (.NET Standard 1.4)

Install ["X.PagedList.Mvc.Core"](http://nuget.org/List/Packages/X.PagedList.Mvc.Core) via [NuGet](http://nuget.org) - that will automatically install ["X.PagedList"](https://nuget.org/packages/X.PagedList/) as well.

### Next steps

2. In your controller code, call **ToPagedList** off of your IEnumerable/IQueryable passing in the page size and which page you want to view.
3. Pass the result of **ToPagedList** to your view where you can enumerate over it - its still an IEnumerable, but only contains a subset of the original data.
4. Call **Html.PagedListPager**, passing in the instance of the PagedList and a function that will generate URLs for each page to see a paging control.



<hr />

## Example
Expand Down
2 changes: 1 addition & 1 deletion src/X.PagedList.Mvc.Core/X.PagedList.Mvc.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<PackageIconUrl>https://ru.gravatar.com/userimage/8071071/f2dc08ee7e4016451f64a7ae9cffd110.png?size=200</PackageIconUrl>
<RepositoryUrl>https://github.com/dncuug/X.PagedList.git</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<Version>1.0.0-beta</Version>
<Version>1.0.1-beta</Version>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit 411c7b0

Please sign in to comment.