I have some jQuery
code and I was wondering is there anyway to convert it to javascript
. like is there a program or something that will help me out?
See the code i'm trying to convert:
$("body").trigger($.Event("keydown", { keyCode: 32 }));
$("body").trigger($.Event("keyup", { keyCode: 32 }));
i tried to translate / convert using api.jquery.com but i failed i'm new to this.
document.querySelectorAll("body").trigger(new Event("keydown", { keyCode: 32 }));