E.apply is not a function when i click

i get the

e.apply is not a function

error, when i click on a “onclick” fuction.
Code example :
<a href="#" onclick="loginpw()" class="">Log In</a>
JS :

function loginpw(){

Error on framework7.js :

    return function() {
    var t = arguments.length <= 0 ? void 0 : arguments[0];
    o && i || (r && t.stopPropagation(), n && t.preventDefault(), i = !0, e.apply(void 0, arguments))}

You might like to abstract the Javascript code from your HTML, keeping the two types more seperated:

HTML file:

<a id="elementInQuestion" href="#" class="">Log In</a>

Javascript file:

var $$ = Dom7;
$$('#elementInQuestion').on('click', function (e) {

Are you using router component?