Kudo/react-native-v8

Build-in polyfills or transformed features out of box

retyui opened this issue · 2 comments

I worked on table https://retyui.github.io/react-native-compat-table/ to compare JS features/engines

And found out, that some of them not available:

  • Promise.any // TypeError: Promise.any is not a function
  • Promise.allSettled // TypeError: Promise.allSettled is not a function

React Native use a promise module


  • async generator async function* () { ... }
  • async iterable for await (let value of range) { ... } // TypeError: Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.

By default used a metro-react-native-babel-preset

Kudo commented

hi there! as you mentioned, even v8 supports native Promise, react-native will still polyfill Promise. how did you verify the Promise supportness for v8?

btw, the comparison looks promising. great job 🤩

not relevant any more