chore: upgrade EqDemo.AspNetCoreReact.AdvancedSearch to .NET 8.0#20
Open
devin-ai-integration[bot] wants to merge 3 commits intomasterfrom
Open
chore: upgrade EqDemo.AspNetCoreReact.AdvancedSearch to .NET 8.0#20devin-ai-integration[bot] wants to merge 3 commits intomasterfrom
devin-ai-integration[bot] wants to merge 3 commits intomasterfrom
Conversation
- Target framework: net6.0 -> net8.0 - Microsoft.EntityFrameworkCore.Sqlite: 6.0.1 -> 8.0.11 - Microsoft.EntityFrameworkCore.SqlServer: 6.0.1 -> 8.0.11 - Microsoft.Data.SqlClient: 2.1.7 -> 5.2.2 - Microsoft.IdentityModel.JsonWebTokens: 6.34.0 -> 6.35.0 - System.IdentityModel.Tokens.Jwt: 6.34.0 -> 6.35.0 - Replace Microsoft.AspNetCore.SpaServices.Extensions with Microsoft.AspNetCore.SpaProxy 8.0.11 - Add SpaProxyLaunchCommand and SpaProxyServerUrl to csproj PropertyGroup - Remove old SPA middleware from Startup.cs (AddSpaStaticFiles, UseSpaStaticFiles, UseSpa/UseReactDevelopmentServer) - Add UseDefaultFiles, MapFallbackToFile for .NET 8 SPA proxy pattern Co-Authored-By: Toby Drinkall <toby.drinkall@cognition.ai>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
…cripts default Co-Authored-By: Toby Drinkall <toby.drinkall@cognition.ai>
… serving Co-Authored-By: Toby Drinkall <toby.drinkall@cognition.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Upgrades the React AdvancedSearch sample project from .NET 6.0 to .NET 8.0, including the breaking migration from the removed
Microsoft.AspNetCore.SpaServices.Extensionsto the newMicrosoft.AspNetCore.SpaProxypattern.csproj changes:
net6.0→net8.0Microsoft.AspNetCore.SpaServices.Extensions6.0.1 → replaced withMicrosoft.AspNetCore.SpaProxy8.0.11Microsoft.EntityFrameworkCore.Sqlite6.0.1 → 8.0.11Microsoft.EntityFrameworkCore.SqlServer6.0.1 → 8.0.11Microsoft.Data.SqlClient2.1.7 → 5.2.2Microsoft.IdentityModel.JsonWebTokens6.34.0 → 6.35.0 (required by SqlClient 5.2.2)System.IdentityModel.Tokens.Jwt6.34.0 → 6.35.0 (same transitive dependency)SpaProxyLaunchCommand(npm start) andSpaProxyServerUrl(http://localhost:3000) properties for dev-time SPA proxyPublishRunWebpacktarget to publish React build output towwwroot/(wasClientApp/build/) so thatUseStaticFiles()can serve it in productionStartup.cs changes:
using Microsoft.AspNetCore.SpaServices.ReactDevelopmentServerAddSpaStaticFiles,UseSpaStaticFiles, andUseSpa/UseReactDevelopmentServercallsUseDefaultFiles()+UseStaticFiles()for serving the built SPA from wwwrootMapFallbackToFile("index.html")insideUseEndpointsfor client-side routingdotnet restoreanddotnet buildpass with 0 errors, 0 warnings.Review & Testing Checklist for Human
dotnet run) and confirm the SPA proxy launches the React dev server onhttp://localhost:3000and the UI loads correctly through the ASP.NET Core host.dotnet publish -c Release, then verify the React build output lands underwwwroot/in the publish directory (notClientApp/build/). Serve the published output and verifyindex.htmlis served for client-side routes via the fallback.PublishRunWebpackfile mapping: The%(RecursiveDir)%(Filename)%(Extension)pattern is intended to strip theClientApp\build\prefix when copying towwwroot\. This was not tested with an actualdotnet publish— onlydotnet buildwas verified.Notes
Microsoft.IdentityModel.JsonWebTokensandSystem.IdentityModel.Tokens.Jwtwere bumped from 6.34.0 → 6.35.0 to resolve a transitive dependency conflict introduced byMicrosoft.Data.SqlClient5.2.2. Without this,dotnet restorefails with NU1605.System.*compatibility packages (System.Net.Http,System.Text.RegularExpressions,System.Drawing.Common,System.Data.SqlClient) were left as-is since the build succeeds without changes. They could be cleaned up in a follow-up.Link to Devin session: https://app.devin.ai/sessions/c46cc86c9d344bfcad3c8d4108483447
Requested by: @tobydrinkall