Multiple dex files error - Can't build any longer - Older Project

This used to happen in the native android apps. No idea how it is appearing on ionic.
Anyways, try with adding the following in your build.gradle

defaultConfig {
    multiDexEnabled true
}