vite-plugin-angular icon indicating copy to clipboard operation
vite-plugin-angular copied to clipboard

Component not resolved

Open ontrigger opened this issue 2 years ago • 1 comments

Adding a new component to the material example throws the following error

ERROR Error: Component 'TestComponent' is not resolved:
 - styleUrl: ./test.component.scss
Did you run and wait for 'resolveComponentResources()'?
    at TestComponent.get (chunk-FKTR2PAS.js?v=1dd6b92b:20062:17)
    at getComponentDef (chunk-FKTR2PAS.js?v=1dd6b92b:5070:14)
    at walkProviderTree (chunk-FKTR2PAS.js?v=1dd6b92b:5218:29)
    at walkProviderTree (chunk-FKTR2PAS.js?v=1dd6b92b:5246:9)
    at chunk-FKTR2PAS.js?v=1dd6b92b:5193:9
    at chunk-FKTR2PAS.js?v=1dd6b92b:4453:77
    at Array.forEach (<anonymous>)
    at deepForEach (chunk-FKTR2PAS.js?v=1dd6b92b:4453:10)
    at internalImportProvidersFrom (chunk-FKTR2PAS.js?v=1dd6b92b:5185:3)
    at _StandaloneService.getOrCreateStandaloneInjector (chunk-FKTR2PAS.js?v=1dd6b92b:19169:25)

To reproduce: clone this repo, navigate to examples/material and run the app https://github.com/ontrigger/vite-plugin-angular

Note that the TestComponent is added to imports of AppComponent

ontrigger avatar Mar 21 '24 09:03 ontrigger

I had the same issue while testing the plugin. The new "styleUrl" syntax seems to not be supported / implemented yet. Would be nice to have for compatibility.

MarcenWare avatar May 21 '24 00:05 MarcenWare