To help me quickly learn new things on the on front-end side, I implemented a small library that generates sample data on the fly.
Suppose you want to learn how angularJS data binding works with ASP.NET MVC WebAPI. You have the following class to play with on the server side:
Now instead of worrying how to create a dozen of fake Books, you can simply write the following:
That will give you a list of twelve sample books. A bit boring, I admit, so how about that:
That’s cool but what if you have Author modelled as a sub class?
No problem, use AddKnownType()
You can find my library on github and on nuget. Just paste the following to package manager console to add reference:
Install-Package DevProductivity_DataTools_DataSampler