I'm trying to do something simple in an ASP.NET Core 1.0 / ASP.net Core Mvc project: get and set simple session variables. But it has proven very difficult. I tried following the advice in this answer, which is to add the dependency -- "Microsoft.AspNet.Session": "1.0.0-beta3" -- to project.json, and then use Context.Session.SetInt("myVar", 35), but that did not work. The SetInt() method is still not recognized.
Do I need to include another dependency? What am I missing?
using Microsoft.AspNet.Http;to your controller file?