>>! In T292244#7393840, @Krinkle wrote:
> Non-existent modules are generally reported client-side in the browser console.
>
> The server-side ClientHtml class doesn't require modules to exist. That's by design to accomodate ParserCache. […]
>
> Instead, we generally handle this on the client-side instead, which also makes it more visible for the front-end developers that work on this code. When a module, or one of its dependencies, is not found in the registry, a warning is logged to the console. The browser doesn't have a way to emit console warnigns from a CSS response, however, so for style modules these currently end up silently ignored.
If we wanted the Parser to have a dependency on ResourceLoader, I suppose we could consider logging a warning server-side if during a fresh parse an added module is not known to the registry, but that feels a bit messy.
Another way might be to add small number of bytes client-side for these cases by letting them be included in the `RLSTATE` object we have for style module names, and then making sure that `mw.loader.state()` logs warnings for unknown modules.
Yet another way might be to build on the footer script we have in ClientHtml for `styleDeprecations`, which also produces console warnings. This has the benefit of requiring zero code in the startup client itself, and no additional code in the `<head>` either. Instead, it would generate exactly the code that is needed without any unused abstractions.