JSFiddle - React, Tailwind, and code Playground

JavaScript

const Test = class Test {
	test() { console.log('a') }
}

const test = new Test();
test.test();

Test.test = () => { console.log('b') };
test.test();