refactor(esproj): drop Microsoft.VisualStudio.JavaScript.Sdk shims#11
Conversation
Replace both PaperlessUI.{Angular,React}.esproj projects with the qyl
hand-rolled MSBuild pattern (qyl/services/qyl.dashboard/qyl.dashboard.esproj),
adapted for pnpm. No more <Project Sdk=...>; custom Restore/Build/Test/Clean
targets shell to pnpm only when RunFrontendOnBuild=true, defaulting to no-op
so CI's dedicated frontend jobs remain the single source of truth.
Removes the entire shim stack that existed only to neutralize the JS SDK:
- <Project Sdk="Microsoft.VisualStudio.JavaScript.Sdk/1.0.5483906">
- <ShouldRunBuildScript>false</ShouldRunBuildScript>
- <ShouldRunNpmInstall>false</ShouldRunNpmInstall>
- <JavaScriptTestRoot>src\</JavaScriptTestRoot> (VS-Windows only)
- <JavaScriptTestFramework>Jasmine|Vitest</...> (VS-Windows only)
- <BuildOutputFolder>$(MSBuildProjectDirectory)\dist\...> (backslashes leaked
literal 'obj\Debug' folders on macOS/Linux every time dotnet build ran)
- <Build Solution="Debug|*"/> opt-in in Paperless.slnx (only needed because
the JS SDK ignored projects that weren't explicitly selected per config)
The bootstrap commit (02ce2b3, today 01:34 UTC+2) hand-typed SDK version
1.0.1641815, which is a Visual Studio Windows internal build number from the
IDE's private NuGet feed and never published to nuget.org — that's why
dotnet build outside VS-Windows failed to resolve it. Dropping the SDK
entirely removes the version-pinning fragility for good.
Both projects still surface their source trees to Rider's solution explorer
via <None Include="src/**/*"/> etc., and 'dotnet build Paperless.slnx'
remains green (0 errors). Real frontend builds keep happening in the pnpm CI
jobs.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Important Review skippedReview was skipped due to path filters ⛔ Files ignored due to path filters (3)
CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
There was a problem hiding this comment.
Pull request overview
Refactors the frontend .esproj projects to remove the dependency on Microsoft.VisualStudio.JavaScript.Sdk, replacing it with minimal hand-rolled MSBuild targets that default to no-ops (keeping CI pnpm jobs as the build source of truth) while still allowing dotnet build Paperless.slnx and IDE project-tree discovery.
Changes:
- Replaced both frontend
.esprojfiles with non-SDK MSBuild projects that expose the source tree via<None Include=...>and provide opt-in pnpmBuildbehavior behindRunFrontendOnBuild=true. - Added no-op
Restore/Testtargets and aCleantarget that removes the dist directory. - Simplified
Paperless.slnxentries for the frontend projects by removing the Debug-only<Build .../>opt-in blocks.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| PaperlessUI.React/PaperlessUI.React.esproj | Drops JS SDK usage; adds hand-rolled MSBuild targets and item globs for project visibility. |
| PaperlessUI.Angular/PaperlessUI.Angular.esproj | Same hand-rolled MSBuild pattern for the Angular frontend. |
| Paperless.slnx | Removes per-config `<Build Solution="Debug |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <Message Text="[PaperlessUI.React] Restore is a no-op; pnpm install runs in the CI frontend job." Importance="low"/> | ||
| </Target> | ||
|
|
||
| <Target Name="Build" DependsOnTargets="Restore"> | ||
| <Message Text="[PaperlessUI.React] Build is a no-op; pnpm run build runs in the CI frontend job." Importance="low"/> | ||
| <Exec Command="$(PnpmExe) install --frozen-lockfile=false" WorkingDirectory="$(FrontendRoot)" Condition=" '$(RunFrontendOnBuild)' == 'true' "/> |
| <Message Text="[PaperlessUI.Angular] Restore is a no-op; pnpm install runs in the CI frontend job." Importance="low"/> | ||
| </Target> | ||
|
|
||
| <Target Name="Build" DependsOnTargets="Restore"> | ||
| <Message Text="[PaperlessUI.Angular] Build is a no-op; pnpm run build runs in the CI frontend job." Importance="low"/> | ||
| <Exec Command="$(PnpmExe) install --frozen-lockfile=false" WorkingDirectory="$(FrontendRoot)" Condition=" '$(RunFrontendOnBuild)' == 'true' "/> |
Summary
Follow-up to #10. Replace both
PaperlessUI.{Angular,React}.esprojfiles with the qyl hand-rolled MSBuild pattern (qyl/services/qyl.dashboard/qyl.dashboard.esproj), adapted for pnpm. No more<Project Sdk=...>; customRestore/Build/Test/Cleantargets shell to pnpm only whenRunFrontendOnBuild=true, defaulting to no-op so the CI frontend jobs remain the single source of truth.Why
Everything in the old esproj existed only to neutralize the JS SDK:
Plus the
<Build Solution="Debug|*"/>opt-in I added in #10 toPaperless.slnxwas only needed because the JS SDK skips projects not explicitly selected per config.The bootstrap commit (
02ce2b3 feat: bootstrap Paperless, 2026-05-12 01:34) hand-typed SDK version1.0.1641815— a VS-Windows internal build from the IDE's private NuGet feed, never published to nuget.org. That's whydotnet buildoutside VS-Windows initially failed to resolve it. Dropping the SDK entirely removes the version-pinning fragility for good.What changes
PaperlessUI.Angular/PaperlessUI.Angular.esprojSdk=, pnpm-shelling targets, source tree exposed via<None Include="src/**/*"/>PaperlessUI.React/PaperlessUI.React.esprojPaperless.slnxTest plan
dotnet build Paperless.slnx— 0 errors, no spuriousobj\Debugliteral-backslash foldersdotnet build Paperless.slnx -c Release -p:ContinuousIntegrationBuild=true— 0 errors, 371 deferred-style warnings (same as feat(sdk): adopt ANcpLua.NET.Sdk 3.4.27 across .NET projects #10)🤖 Generated with Claude Code