Skip to content

Ideas for improvement of dev inner loop with scoped CSS development and dotnet watch run #27555

@rogihee

Description

@rogihee

One of the more tedious tasks in building any app is of course the endless cycle of tinkering for the correct shade of grey for that input border. Scoped CSS is really, really great! But after extensively using dotnet watch run for building a Blazor WebAssembly app, let's just say we have had ample time to think of some improvements in the development inner loop in this area :-).

  1. Make 'dotnet watch run' smarter for the type of file that is changed. For CSS file change, only a few tasks need to run, not the full build pipeline. Furthermore, only the touched scoped css files could be diffed into the generated CSS file, without gobbling / touching the other files.
  2. Scoped CSS file is just a file, it doesn't need a full host restart. Just set the correct headers to force reload of that file and trigger refresh, but not a restart of the whole host.
  3. A huge, huge time saver would be the possibility to directly edit scoped CSS files the browser DEV tools back to razor.css file using a map file like TypeScript files via the Filesystem in the Sources tab.

See also: #27270

Metadata

Metadata

Assignees

No one assigned

    Labels

    Pillar: Dev ExperiencePriority:3Work that is nice to haveTheme: inner-loopaffected-very-fewThis issue impacts very few customersarea-blazorIncludes: Blazor, Razor Componentsarea-commandlinetoolsIncludes: Command line tools, dotnet-dev-certs, dotnet-user-jwts, and OpenAPIenhancementThis issue represents an ask for new feature or an enhancement to an existing onefeature-css-isolationThis issue is related to CSS Isolation featurefeature-dotnetwatchThis issue is related to the dotnet-watch command-line tool (now external)feature-hot-reloadThis issue is related to the Hot Reload feaaturereevaluateWe need to reevaluate the issue and make a decision about itseverity-nice-to-haveThis label is used by an internal tool

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions