AOT build fail on android


i run

tns build android --bundle --env.uglify --env.aot --env.snapshot

get following error, no other information

ERROR in Cannot read property 'map' of undefined
Executing webpack failed with exit code 2.

Then i made some attempts

  1. tns run android --env.aot
  2. tns run android --bundle --env.aot
    fail, same error msg
  3. tns run android --bundle --env.uglify
  4. tns run android --env.uglify --env.aot

It seems that the bundle option can affect aot building

tns info

nativescript 4.1.0
tns-core-module 4.1.0
tns-android 4.1.3


I replace all arrays like…) with (xxx || []).map(…)
and all observables like xxx$.map(…) with xxx$.pipe(map(…)) (i use rxjs 6.6)
But the issue is still there.