I'd prefer to have it the MobileDetect lib only as a suggest.
But if it has to be require, then in the app.