How to use ol library in frappe custom app

Hi all,

I was trying to build a dummy custom application with ol (OpenLayers) library.
However, I found out that it’s not working -

The error is because of optional chaining or (??)

How can we solve this issue in Frappe custom app?

Node Version: 16
Vue 2 or Vue 3