Skip to content

Support Html requests in cohosting #8210

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Apr 25, 2025

Conversation

davidwengier
Copy link
Member

Part of dotnet/razor#11759

This is the guts of how html requests work in cohosting. Relatively simple, most of the work is now on the server. Also adds support for document color and color presentation as the first two test candidates.

) {
const logNotificationType = new NotificationType<LogMessageParams>('razor/log');
languageServer.registerOnNotificationWithParams(logNotificationType, (params) =>
razorLogger.log(params.message, params.type)
);

if (!razorOptions.cohostingEnabled) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to remove registration of dynamicFile endpoints if cohosting is on?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think so. I think we never call them (though tbh I've put almost no effort into initialization yet)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can be another pr for sure

@davidwengier davidwengier merged commit d624719 into dotnet:main Apr 25, 2025
24 checks passed
@davidwengier davidwengier deleted the CohostDocColor branch April 25, 2025 04:19
davidwengier added a commit to dotnet/razor that referenced this pull request Apr 25, 2025
Part of #11759

Razor side of dotnet/vscode-csharp#8210

This PR does the infra for html requests in cohosting, and ports
document color as the first test case. It's extremely simple after the
re-layering PR from the other day :)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants