One of the advantages of Magisk is the ability to make modifications to your device systemlessly, which in turn allows to retain you to retain the ability to pass SafetyNet checks for Android Pay and other services.

XDA Member VR25 has put together a Magisk module that allows you to enable Miracast and Tethering as well as disable ADB Notify. The module achieves this by modifying the build.prop and adding these lines: