I did read your post and I did open your project and I did fix the issues in your code.
-
1) needs to be fixed regardless of 2)
-
2) is a pas2js transpiler shortcoming but the problem in your code remains and I suggested how to fix it.
The async error is because of 1)