console.log not working in use function
I'm trying to write some logic in JavaScript file in my custom component but the use function is not firing the console.log. Does anyone know why it won't work. I even tried using window.alert but that won't work either. but I can create a var and assign a string value and display that value through expression in HTL.
Here is the the JS code.
use(function () {
var props = {
test: "test",
test2: "test2"
};
console.log("----------------Test_---------")
return {
// anything exposed here can be used inside your template
props: props,
};
});