mariuszfoltak/angular2-datatable

Unexpected module 'DataTableModule' declared by the module 'AppModule'

Opened this issue · 1 comments

When i tried to implement this, i am getting the below error...I am using Webpack packaging for my project.

An unhandled exception occurred while processing the request.

Exception: Call to Node module failed with error: Error: Unexpected module 'DataTableModule' declared by the module 'AppModule'
at D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules@angular\compiler\bundles\compiler.umd.js:14174:33
at Array.forEach (native)
at CompileMetadataResolver.getNgModuleMetadata (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules@angular\compiler\bundles\compiler.umd.js:14161:51)
at RuntimeCompiler._compileComponents (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules@angular\compiler\bundles\compiler.umd.js:16803:49)
at RuntimeCompiler._compileModuleAndComponents (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules@angular\compiler\bundles\compiler.umd.js:16741:39)
at RuntimeCompiler.compileModuleAsync (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules@angular\compiler\bundles\compiler.umd.js:16732:23)
at NodePlatform.bootstrapModule (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules\angular2-platform-node\node-platform.js:436:25)
at NodePlatform.serializeModule (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules\angular2-platform-node\node-platform.js:108:22)
at D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\ClientApp\dist\main-server.js:71:63
at ZoneDelegate.invoke (D:\Babu\Angular2\ecapp_master\Verizon.ECApp.UI2\Verizon.ECApp.UI2\node_modules\zone.js\dist\zone-node.js:232:26)

I am getting this too. For what it's worth, I did not receive this error when using angular 2.0.0 but did after upgrading to 2.4.4. If I figure out how to fix, I'll post back.

Update: I don't know what I did to fix this error. I reinstalled my dependencies, rebuilt the JS, and hard refreshed in the browser, and now I no longer receive this error on 2.4.4.