If somehow we can make h5p work the wplms h5p will also work.
I added following script js/h5p.js in autooptimize settings, but its not enough, now another error starts appearing.
For fastest way to resolve this would be to contact Autoptimize guys and ask them if h5p can work with the Script minification settings.