C
C#

help

❔ ASP.NET Core reroute requests for static files to a different server

AAnton11/8/2022
This is supposed to be implemented by Microsoft.AspNetCore.SpaServices.Extensions, like this guy does here https://github.com/MakotoAtsu/AspNetCore_Vite_Template However there's an issue: I want a) to be able to start the server separately, b) to use the manifest generated by Vite to provide the files. The code in the template above doesn't actually work as I need it to: it looks at the dist folder to get the available files, while what should actually happen is it should read in the manifest file generated by vite, which remaps the files correctly and whatnot. So I need a custom FileProvider. The problem with that is the method GetFileInfo, which returns an IFileInfo, which has to implement CreateReadStream(), which I have no idea why aspnet core needs in the first place, and I don't know how to implement it myself. The implementations provided by aspnet core deal with actual files on disk or embedded resources, but not files streamed over http, so idk what to do.
UUUnknown User11/8/2022
Message Not Public
Sign In & Join Server To View
AAnton11/9/2022
yeah this might be good enough one question tho: is it possible to conditionally rebind the urls of image tags and style imports in razor views? is there some sort of plugin system to do this at compile time maybe? just dropping the question here, but I'll investigate on my own too of course startup time* this might work
AAnton11/9/2022
I wonder if there is something similar just for attributes that expand into other attributes
AAccord11/22/2022
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.

Looking for more? Join the community!

Want results from more Discord servers?
Add your server
Recommended Posts
Avoid line break and wrapping (Formatting in rider)What is the most common way to format codes in rider when a line is long? Break lines or wrapping. L✅ Source-gen on a .shprojI have a project with one shproj and multiple csprojs. However, the source-generators added to the c❔ API doesnt return dynamic object in ASP.NET Core 2.0I am looking to return a list from a Dynamic linq query but the problem comes when returning the lisSqlite package breaks maui app.Im running a maui blazor hybrid project and added another repository project in the solution. In thegit push error 502I get this error when pushing the entire project in new remote repo ``` git push origin ios/master How to force implementation of concrete interface methodsHow do I force the default the requirement for implementation of interface methods which have a bodyhow to use ReflectionAnalyzershow to check for reflection warnings in my project (net standard 2.0)? it uses some other nuget packcan anyone help with a wpf issue i’m havinghttps://stackoverflow.com/questions/74328324/gridviewcomboboxcolumn-not-showing-dropdown-until-clickWinforms DataGridView issue when setting column header texti cant figure out why, but setting the header text to "N/A" works totally fine, but setting it to "M.net Framework Console app check against modification and best practice deploy for auto update.Hey Everyone, i am creating an console app right now which i want to deploy in the next days. The GiFrontend package management in ASP.NET CoreThe Microsoft docs apparently recommend libman https://learn.microsoft.com/en-us/aspnet/core/client-Creating a file with a fixed sizeI am writing a video splitter app for my personal storage and would like some help. What my app doeGetting the result from a list of tasksIts been a minute since I have done async methods but i know i can do a list of tasks I just think IDiff between the Ilist and List- IList<int> res = new List<int>(); - List<int> res = new List<int>(); what is the difference betweeKeep up with Db(First)How do I keep up with my Db changes with DbFirst way? Do I rescaffold it every time I make a change?How to kill a process ?I just know about process killing and try to test it, here is my code: ```csharp using System.DiagnXUnit crashing when a stack overflow occurs.Hello, I am using XUnit to test untrusted student code. Thing is, whenever a stack overflow occurs (I need directions.i wish to learn and understand how to create and use a application window without using Winforms, WP