thangchung / blog-core

Modular blog using Blazor with clean domain-driven design patterns
MIT License
407 stars 124 forks source link

while waiting for an application based on net.core 3.0. from you, I tried to be able to use the netcore 2.0 application. but an error appeared. #20

Closed BionStt closed 5 years ago

BionStt commented 5 years ago

haii...@thangchung i am student. i'm learning clean code architecture. for this sample code. i already tried in windows powershell

dotnet restore npm install node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js node node_modules/webpack/bin/webpack.js

(my version node v11.14.0 and npm v6.9.1-next.0) is this problem in typescript depencies or redux >?

thanks you. Bion

and this is the result :


Hash: 609dbf83acef32af8343393c000451260c5b0501
Version: webpack 3.12.0
Child
    Hash: 609dbf83acef32af8343
    Time: 47667ms
                                   Asset      Size  Chunks                    Chunk Names
    674f50d287a8c48dc19ba404d20fe713.eot    166 kB          [emitted]         
    b06871f281fee6b241d60582ae9369b9.ttf    166 kB          [emitted]         
    912ec66d7572ff821749319396470bde.svg    444 kB          [emitted]  [big]  
    2fe2efe63441d830b1acd106c1fe8734.svg    239 kB          [emitted]         
                          main-client.js   2.15 MB       0  [emitted]  [big]  main-client
                                site.css    924 kB       0  [emitted]  [big]  main-client
                      main-client.js.map   2.56 MB       0  [emitted]         main-client
                            site.css.map  85 bytes       0  [emitted]         main-client

    ERROR in [at-loader] ./ClientApp/containers/Blog/BlogManagement.tsx:12:23 
        TS2344: Type '{ page: number; }' does not satisfy the constraint '{ page?: string | undefined; }'.
      Types of property 'page' are incompatible.
        Type 'number' is not assignable to type 'string | undefined'.

    ERROR in [at-loader] ./ClientApp/redux/modules/blog.ts:281:14 
        TS2322: Type '(state: BlogState, action: KnownAction) => BlogState | { blogSelected: any; loaded: true; loading...' is not assignable to type 'Reducer<B
logState>'.
      Types of parameters 'action' and 'action' are incompatible.
        Type 'AnyAction' is not assignable to type 'KnownAction'.
          Type 'AnyAction' is not assignable to type 'DeleteBlogFailedAction'.
            Property 'error' is missing in type 'AnyAction'.

    ERROR in [at-loader] ./ClientApp/redux/modules/common.ts:20:14 
        TS2322: Type '(state: CommonState, action: RedirectToAction) => CommonState | { to: string | null; redirectTo: ...' is not assignable to type 'Reducer<C
ommonState>'.
      Types of parameters 'action' and 'action' are incompatible.
        Type 'AnyAction' is not assignable to type 'RedirectToAction'.
          Property 'to' is missing in type 'AnyAction'.
    Child extract-text-webpack-plugin ../../../../../../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\extract-text-we
bpack-plugin\dist ../../../../../../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\css-loader\index.js!../../../../../
../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\font-awesome\css\font-awesome.min.css:
         3 assets
    Child extract-text-webpack-plugin ../../../../../../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\extract-text-we
bpack-plugin\dist ../../../../../../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\css-loader\index.js!../../../../../
../../../Dermawan Gasali\source\repos\bionstt\blog-core\src\hosts\BlogCore.App\node_modules\simple-line-icons\css\simple-line-icons.css:
         1 asset
Child
    Hash: 393c000451260c5b0501
    Time: 29999ms
             Asset     Size  Chunks                    Chunk Names
    main-server.js  4.86 MB       0  [emitted]  [big]  main-server

    ERROR in [at-loader] ./ClientApp/containers/Blog/BlogManagement.tsx:12:23 
        TS2344: Type '{ page: number; }' does not satisfy the constraint '{ page?: string | undefined; }'.
      Types of property 'page' are incompatible.
        Type 'number' is not assignable to type 'string | undefined'.

    ERROR in [at-loader] ./ClientApp/redux/modules/blog.ts:281:14 
        TS2322: Type '(state: BlogState, action: KnownAction) => BlogState | { blogSelected: any; loaded: true; loading...' is not assignable to type 'Reducer<B
logState>'.
      Types of parameters 'action' and 'action' are incompatible.
        Type 'AnyAction' is not assignable to type 'KnownAction'.
          Type 'AnyAction' is not assignable to type 'DeleteBlogFailedAction'.
            Property 'error' is missing in type 'AnyAction'.

    ERROR in [at-loader] ./ClientApp/redux/modules/common.ts:20:14 
        TS2322: Type '(state: CommonState, action: RedirectToAction) => CommonState | { to: string | null; redirectTo: ...' is not assignable to type 'Reducer<C
ommonState>'.
      Types of parameters 'action' and 'action' are incompatible.
        Type 'AnyAction' is not assignable to type 'RedirectToAction'.
          Property 'to' is missing in type 'AnyAction'.
BionStt commented 5 years ago

sorry, i have repair the code. just change knowaction to anyaction. thank you