Quantcast
Channel: Active questions tagged nuget-package - Stack Overflow
Viewing all articles
Browse latest Browse all 3067

How to create a mvc nuget package, that contains logic (controller-like)

$
0
0

I would like to create a nuget package for ASP.NET MVC (and ASP.NET Core MVC) applications.

The result should be a package, that you only need to activate via middleware like:

app.UseXyz()

and that reacts to a specific route ie URL:PORT/logtrace.

And I already created a middleware component that can return a web response to a route, but I can only work with basic httprequests inside of the middleware.

Since the logic, I want to program is more complex, I would need something like MVC controllers to utilize POST/GET requests and views.

Can I somehow use the MVC pattern inside an Owin middleware? Or is there even an easier way that I could not come up with, for creating a nuget package, that handles specific routes with controllers/views?


Viewing all articles
Browse latest Browse all 3067

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>