All Projects → mcintyre321 → EmbeddedResourceVirtualPathProvider

mcintyre321 / EmbeddedResourceVirtualPathProvider

Licence: MIT license
A custom VirtualPathProvider for IIS - load views and assets from Embedded Resources in referenced assemblies

Programming Languages

C#
18002 projects
Classic ASP
548 projects
pascal
1382 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to EmbeddedResourceVirtualPathProvider

Templates
.NET project templates with batteries included, providing the minimum amount of code required to get you going faster.
Stars: ✭ 2,864 (+4519.35%)
Mutual labels:  asp-net
Home
Home for Blazor Extensions
Stars: ✭ 51 (-17.74%)
Mutual labels:  asp-net
DNZ.SEOChecker
SEO Checker and Recommander Plugin (like wordpress Yoast) for ASP.NET Core.
Stars: ✭ 18 (-70.97%)
Mutual labels:  asp-net
Nlog.web
NLog integration for ASP.NET & ASP.NET Core 1-5
Stars: ✭ 252 (+306.45%)
Mutual labels:  asp-net
FlexDotnetCMS
A powerful, flexible, decoupled and easy to use and Fully Featured ASP .NET CMS, it can also be used as a Headless CMS
Stars: ✭ 45 (-27.42%)
Mutual labels:  asp-net
ByteScout-SDK-SourceCode
ALL source code samples for ByteScout SDKs and Web API API products.
Stars: ✭ 24 (-61.29%)
Mutual labels:  asp-net
Docker On Windows
Code samples for the book "Docker on Windows"
Stars: ✭ 213 (+243.55%)
Mutual labels:  asp-net
squidex-samples
Samples for Squidex
Stars: ✭ 47 (-24.19%)
Mutual labels:  asp-net
TextMood
A Xamarin + IoT + Azure sample that detects the sentiment of incoming text messages, performs sentiment analysis on the text, and changes the color of a Philips Hue lightbulb
Stars: ✭ 52 (-16.13%)
Mutual labels:  asp-net
squidex-identity
Identity Server for Squidex Headless CMS
Stars: ✭ 28 (-54.84%)
Mutual labels:  asp-net
project-lighthouse
Project Lighthouse is a clean-room, open-source custom server for LittleBigPlanet.
Stars: ✭ 139 (+124.19%)
Mutual labels:  asp-net
BlipBinding
ASP.NET MVC case study solution for PluralSight Guides. Demonstrates how to use default MVC model binding with hierarchical form data.
Stars: ✭ 29 (-53.23%)
Mutual labels:  asp-net
Self-Hosted-Asp.Net-WebHooks
Self hosted custom webhook receiver and sender
Stars: ✭ 50 (-19.35%)
Mutual labels:  asp-net
Dasblog Core
The original DasBlog reimagined with ASP.NET Core
Stars: ✭ 252 (+306.45%)
Mutual labels:  asp-net
WebApiToTypeScript
A tool for code generating TypeScript endpoints for your ASP.NET Web API controllers
Stars: ✭ 26 (-58.06%)
Mutual labels:  asp-net
Falco
A functional-first toolkit for building brilliant ASP.NET Core applications using F#.
Stars: ✭ 214 (+245.16%)
Mutual labels:  asp-net
codegenerator
Generate EF6 WebApi with an AngularJS font-end
Stars: ✭ 11 (-82.26%)
Mutual labels:  asp-net
Uintra
A flexible and lightweight Umbraco based framework, for making an Intranet, Extranet or social platform based on known conventions.
Stars: ✭ 43 (-30.65%)
Mutual labels:  asp-net
PersianDataAnnotations
PersianDataAnnotations is ASP.NET Core MVC & ASP.NET MVC Custom Localization DataAnnotations (Localized MVC Errors) for Persian(Farsi) language - فارسی سازی خطاهای اعتبارسنجی توکار ام.وی.سی. و کور.ام.وی.سی. برای نمایش اعتبار سنجی سمت کلاینت
Stars: ✭ 38 (-38.71%)
Mutual labels:  asp-net
web-schedule-course
🚪 基于ASP.NET和SQL Server数据库开发的排课系统(web开发课程设计)
Stars: ✭ 40 (-35.48%)
Mutual labels:  asp-net

EmbeddedResourceVirtualPathProvider

A custom VirtualPathProvider for IIS - load views and assets from Embedded Resources in referenced assemblies . To get started, install into your ASP.NET web application via nuget:

Install-Package EmbeddedResourceVirtualPathProvider

This will add some code into App_Start registering the provider.

Move views and assets into other assemblies, maintaining folder structure. e.g.

/MyAspNetApp/Views/Thing/Thing.cshtml -> /ThingComponent/Views/Thing/Thing.cshtml

And set the the files BuildAction as EmbbeddedResource. Make sure your assembly is referenced, and you're done!

By default, all assemblies in the appdomain are scanned. You can restrict this in App_Start\EmbeddedResourceVirtualPathProviderStart.cs file. You can also map assemblies to their location on disk, so they ca nbe refereshed when you edit the files during development.

There is some help at https://github.com/mcintyre321/EmbeddedResourceVirtualPathProvider/wiki/Help

Install Actions

On installing the package we'll get:

  • App_Start/EmbeddedResourceVirtualPathProviderStart.cs file created - it contains provider registration via WebActivator
  • section system.webServer/handlers in web.config will be updated with:
<add verb="GET" path="*.js" name="Static for js" type="System.Web.StaticFileHandler" />
<add verb="GET" path="*.css" name="Static for css" type="System.Web.StaticFileHandler" />
<add verb="GET" path="*.png" name="Static for png" type="System.Web.StaticFileHandler" />
<add verb="GET" path="*.jpg" name="Static for jpg" type="System.Web.StaticFileHandler" />
  • WebActivatorEx package will be installed

If you don't want all these side effects then use package EmbeddedResourceVirtualPathProvider.Core which contains only an assembly.

Dynamic Content Routing

You can set up rules determining the order to check assemblies for resources, letting you (for example) have different view assemblies for different hostnames.

Please check out my other projects!

Cheers, Harry

@mcintyre321

MIT Licenced

Bitdeli Badge

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].