Skip to content

Reimplement the Razor compiler using source generators & support incrementality #26902

Closed
@pranavkm

Description

@pranavkm

Summary

The Razor compiler today represents a significant portion of time experienced by developers in inner-loop scenarios. We should investigate reimplementing it to be based on source generators to avoid the cost of an extra discrete step and removal of another process associated with building.

Today, the Razor compilation process is non-incremental, meaning even the smallest change to any Razor file results in a complete build of all Razor assets in a project. We should investigate the potential for adding further incrementality to Razor compilation so that unnecessary compilation time is not spent between edits.

Notes

The hypothesis is that an additional compile step can be eliminated along with state management if we are able to use source generators. We might also benefit of not producing janky types in design time builds.

Tasks

Metadata

Metadata

Assignees

Labels

DoneThis issue has been fixedEpicGroups multiple user stories. Can be grouped under a theme.Priority:0Work that we can't release withoutTheme: inner-loopaffected-allThis issue impacts all the customersenhancementThis issue represents an ask for new feature or an enhancement to an existing onefeature-source-generatorsseverity-blockingThis label is used by an internal tool

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions