I tried getting NgModules to work, but it looks like my naive copy/paste of the IvyComponent trick…
Isaac Mann
32

Issac, first of all — it’s great to see you experimenting with this and trying to take it even one step further. I believe the reason it doesn’t work for you is that the Angular build you are using (the one that is available on NPM) was not built with Ivy, and thus, Angular’s own directives and modules don’t have the metadata that Ivy expects to find.

Joost Koehoorn experimenting with trying to make the development builds of Ivy work within StackBlitz, you can find his work-in-progress here:

It seems like he had it working at some point, but I couldn’t get it to work at my end, getting a bunch of CORS errors:

I did manage to get a similar setup working locally though, just by replacing all the “@angular” dependencies with their github counterparts in my package.json, e.g.

"@angular/core": "angular/core-builds#master-ivy-jit",
"@angular/common": "angular/common-builds#master-ivy-jit",

etc.

I’d love to see you keep on experimenting and sharing some interesting results :-)