dotnet / dotnet/AspNetCore.Docs

Adding PrepareForBuildDependsOn section as instructed disables PreComputeCompileTypeScriptWithTSConfig task

Open
#34,415 1 comment 0 reactions 0 assignees View on GitHub
aspnet-core/svc razor-pages/subsvc Source - Docs.ms waiting-on-feedback
Dominant language
C#
Stars
13.1k
Forks
24.6k
Avg merge
1d 2h
Merged PRs (30d)
109

Description

### Description

The documentation suggests adding a `...` section to integrate TypeScript compilation into the project, however doing so will cause the `PreComputeCompileTypeScriptWithTSConfig` task to be skipped, possibly because the `tsconfig.json` file is not yet available in the content file list at that stage in the build? The end result is that `tsconfig.json` cannot be used when the `PrepareForBuildDependsOn` element is added as instructed in the documentation.

This is potentially additionally a more critical issue in the .net 9 SDK, as it appears the build will error at the static file fingerprinting stage if the `PrepareForBuildDependsOn` element is NOT added.

### Page URL

https://learn.microsoft.com/en-us/aspnet/core/razor-pages/ui-class?view=aspnetcore-8.0&tabs=visual-studio#typescript-integration

### Content source URL

https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/razor-pages/ui-class.md

### Document ID

fd116d00-0dc7-efaf-c714-34d77b345a05

### Article author

@tdykstra

[Related Issues](https://github.com/dotnet/AspNetCore.Docs/issues?q=is%3Aissue+is%3Aopen+fd116d00-0dc7-efaf-c714-34d77b345a05)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.