angular: "this.marshal is undefined" when ivy is enabled and flex-layout used
🐞 bug report
Affected Package
The issue is caused PROBABLY by @angular/flex-layout or IVY
Is this a regression?
it works without ivy elabled
Description
when updated my project to v8 everything was ok. then i enabled ivy and it is not ok - it compiles ok but when i try open this app then in console it throws error If i comment out import of FlexLayoutModule then erros is gone but also flexlayout is gone 😉
also tried new clean project to se if it is project related and no in new project it is the same.
🔬 Minimal Reproduction
any new project with 8.2 version and ivy enabled and FlexLayoutModule installed / loaded into module
and then any flex command in template like
<div fxLayout="row" fxLayoutAlign="center"></div>
🔥 Exception or Error
columnNumber: 9
fileName: "http://localhost:4200/vendor.js"
lineNumber: 76971
message: "this.marshal is undefined"
stack: "init@http://localhost:4200/vendor.js:76971:9\nLayoutDirective@http://localhost:4200/vendor.js:81202:9\nDefaultLayoutDirective@http://localhost:4200/vendor.js:81214:15\nɵɵgetInheritedFactory/<@http://localhost:4200/vendor.js:42338:16\nDefaultLayoutDirective_Factory@http://localhost:4200/vendor.js:81218:582\ngetNodeInjectable@http://localhost:4200/vendor.js:42202:36\ninstantiateAllDirectives@http://localhost:4200/vendor.js:47869:27\ncreateDirectivesAndLocals@http://localhost:4200/vendor.js:47239:5\nɵɵelementStart@http://localhost:4200/vendor.js:55832:5\nLoginComponent_Template@http://localhost:4200/main.js:337:9\nexecuteTemplate@http://localhost:4200/vendor.js:47187:9\ncheckView@http://localhost:4200/vendor.js:48611:9\ncomponentRefresh@http://localhost:4200/vendor.js:48369:9\nrefreshChildComponents@http://localhost:4200/vendor.js:46868:13\nrefreshDescendantViews@http://localhost:4200/vendor.js:46767:5\nrenderEmbeddedTemplate@http://localhost:4200/vendor.js:47117:13\ncreateEmbeddedView@http://localhost:4200/vendor.js:50259:17\ncreateEmbeddedView@http://localhost:4200/vendor.js:50367:33\n_updateView@http://localhost:4200/vendor.js:31315:25\nset ngIf@http://localhost:4200/vendor.js:31280:9\nsetInputsForProperty@http://localhost:4200/vendor.js:48747:13\nelementPropertyInternal@http://localhost:4200/vendor.js:47589:9\nɵɵproperty@http://localhost:4200/vendor.js:54099:9\nAppComponent_Template@http://localhost:4200/main.js:162:9\nexecuteTemplate@http://localhost:4200/vendor.js:47187:9\ncheckView@http://localhost:4200/vendor.js:48611:9\ncomponentRefresh@http://localhost:4200/vendor.js:48369:9\nrefreshChildComponents@http://localhost:4200/vendor.js:46868:13\nrefreshDescendantViews@http://localhost:4200/vendor.js:46767:5\nrenderComponentOrTemplate@http://localhost:4200/vendor.js:47158:9\ntickRootContext@http://localhost:4200/vendor.js:48517:9\ndetectChangesInRootView@http://localhost:4200/vendor.js:48553:5\ndetectChanges@http://localhost:4200/vendor.js:50127:23\ntick@http://localhost:4200/vendor.js:71619:17\n_loadComponent@http://localhost:4200/vendor.js:71670:9\nbootstrap@http://localhost:4200/vendor.js:71593:9\n_moduleDoBootstrap/<@http://localhost:4200/vendor.js:71214:18\n_moduleDoBootstrap@http://localhost:4200/vendor.js:71210:13\nbootstrapModuleFactory/</</<@http://localhost:4200/vendor.js:71165:21\ninvoke@http://localhost:4200/polyfills.js:368:17\nonInvoke@http://localhost:4200/vendor.js:70437:24\ninvoke@http://localhost:4200/polyfills.js:367:37\nrun@http://localhost:4200/polyfills.js:133:24\nscheduleResolveOrReject/<@http://localhost:4200/polyfills.js:864:31\ninvokeTask@http://localhost:4200/polyfills.js:400:17\nonInvokeTask@http://localhost:4200/vendor.js:70418:24\ninvokeTask@http://localhost:4200/polyfills.js:399:41\nrunTask@http://localhost:4200/polyfills.js:177:28\ndrainMicroTaskQueue@http://localhost:4200/polyfills.js:568:25\n
🌍 Your Environment
Angular Version:
Angular CLI: 8.2.0
Node: 12.7.0
OS: win32 x64
Angular: 8.2.0
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router
Package Version
-----------------------------------------------------------
@angular-devkit/architect 0.802.0
@angular-devkit/build-angular 0.802.0
@angular-devkit/build-optimizer 0.802.0
@angular-devkit/build-webpack 0.802.0
@angular-devkit/core 8.2.0
@angular-devkit/schematics 8.2.0
@angular/cdk 8.1.2
@angular/flex-layout 8.0.0-beta.26
@angular/material 8.1.2
@ngtools/webpack 8.2.0
@schematics/angular 8.2.0
@schematics/update 0.802.0
rxjs 6.4.0
typescript 3.5.3
webpack 4.38.0
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 3
- Comments: 18 (10 by maintainers)
Thx, @Splaktar 🚀 Closing this issue. Please open a new one, if there are still problems.
Added the release, thanks for reminding me.
The next release has been published, v8.0.0-beta.27.
@kara I verified that this has been resolved in
@angular/flex-layout
as part of thev8.0.0-beta.27
release.@Splaktar To support earlier versions, the lib can add a constructor to the extended class or add a
@Directive
decorator that has a selector. It doesn’t need to be selector-less.