Should I have one <Manager> component at the root of my whole project or is it better to have one <Manager> for each place I want to pop up content? So for example, one wrapped around every drop down menu and every hover tooltip?
Should I have one <Manager> component at the root of my whole project or is it better to have one <Manager> for each place I want to pop up content? So for example, one wrapped around every drop down menu and every hover tooltip?
Definitely wrap every reference element, as you can see that's done in the official repo's demo:
https://github.com/FezVrasta/react-popper/blob/master/demo/index.js#L61
If you look at the source code, you'll see that the Reference component uses a Context Consumer to save a reference to the parent Manager component.