JSFiddle - React, Tailwind, and code Playground
by ChrisStanyon
HTML
<button onclick="check()">
Default Context
</button>
<button onclick="check.call(this)">
New Context
</button>
<button onclick="check2()">
Not strict
</button>
JavaScript
function check(element) {
'use strict';
console.log(this)
console.log(event)
console.log(element)
}
function check2() {
console.log(this)
}