ionic2 Navigation error and How to fix it.

I try ionic2 navigation tutorial from many website but got error as shown below.

Error: Component About is not part of any NgModule or the module has not been imported into your module.

Examples of tutorial that will cause you an error.

Navigation in ionic2 is simple you can follow tutorials above. And just add more step here to fix the error.

Add following code to app.module.ts file

  1. import your SecondPage
  2. Add your SecondPage in @NgModule declarations and entryComponents
Fixing error in ionic2 navigation tutorial

The navigation concept in ionic2 is very simple. It use concept of push and pop like stacking plates. After you can fixed this error, you will enjoy new concept of ionic2 navigation.