Closed turansky closed 4 years ago
Hi @turansky
As a temporary workaround you may use 3.0.3 version, run npm i mobx-angular@3.0.3
to install. NG 9 is still a release candidate, so there might be some issues.
Hi @adamkleingit it looks like the spread syntax in module declaration triggers an error in NG 9: https://github.com/mobxjs/mobx-angular/blob/243fdfe851571679e761f696c3806f59651d7fac/lib/mobx-angular.ts#L26 There are similar issues: https://github.com/angular/angular/issues/29835, https://github.com/coryrylan/ngx-lite/pull/23
I'll create a fix soon.
@kubk, thank you for workaround. Will it be fixed in 3.* version?
Hi @turansky Angular 9 RC 11 should contain a fix for this issue: https://github.com/angular/angular/commit/d749dd3ea1865c2ff7252415227e0210bea96983
Can you confirm updating to RC 11 works for you?
Hi @kubk!
Angular 9.0.0-rc.13
+ MobX 3.1.0
doesn't work (same problem).
Angular 9.0.0-rc.13
+ MobX 3.0.3
works fine.
It doesn't work for me either. @adamkleingit It seems like this fix is still required: https://github.com/mobxjs/mobx-angular/pull/113
Just checked with a fresh Angular 9 project (official stable release as of earlier today) and this version doesn't work. Downgrading mobx-angular
to 3.0.3
does work as a workaround until a fix is released.
ERROR in Failed to compile entry-point angular-tree-component (module as esm5) due to compilation errors: node_modules/angular-tree-component/node_modules/mobx-angular/dist/mobx-angular.d.ts:5:22 - error NG6002: Appears in the NgModule.imports of TreeModule, but could not be resolved to an NgModule class
5 export declare class MobxAngularModule {
"@angular/core": "~9.0.0", "mobx-angular": "3.1.0", "mobx-angular": "3.0.3",
How do you fix this... it’s still a problem!
Hi @turansky please try 3.1.1, it should work. Hi @juliocardosoventura , angular-tree-component package requires 3.0.3 version: https://github.com/500tech/angular-tree-component/blob/master/package.json#L70 The error described in this issue is only reproducible on 3.1.0.
Hi @turansky please try 3.1.1, it should work.
It works! @kubk thank you!
@turansky Great, would you mind closing this issue?
Fixed in 3.1.1
I get below error with angular 9
node_modules/mobx/lib/api/flow.d.ts:9:108 - error TS2304: Cannot find name 'AsyncGenerator'.
9 export declare function flow<R, Args extends any[]>(generator: (...args: Args) => Generator<any, R, any> | AsyncGenerator<any, R, any>): (...args: Args) => CancellablePromise
@debender495 This is a known issue and it is related to TypeScript, not Mobx: https://github.com/mobxjs/mobx/pull/2225/files#diff-b0aca01070f80bb35c361f0308eb0170R15
Is it known problem? Is there known solution for it?