Read the paper at https://link.springer.com/article/10.1007%2Fs10654-021-00757-1
Mendelian randomisation for mediation analysis: current methods and challenges for implementation

Mediation analysis seeks to explain the pathway(s) through which an exposure affects an outcome. Traditional, non-instrumental variable methods for mediation analysis experience a number of methodological difficulties, including bias due to confounding between an exposure, mediator and outcome and measurement error. Mendelian randomisation (MR) can be used to improve causal inference for mediation analysis.