react-native-menu / menu

UIMenu Component for React Native

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to change position of Menu on iOS?

Andrea-Arguello opened this issue · comments

image
The menu is showing up above the button, I would like for it to show up underneath it. On Android it is showing below, as expected.

This seems to happen based on the component's position, as if it is closer to the top, it renders it below. It is also interesting to note that in the above image, it also reverts the order of the components.
Is there a way to fix its position?

Since the actions are in an array you can sort them. An easier way is to write the items as you would then reverse the array.

     actions={
          [...yourActions].reverse()
     }