Kumi
303258ce10
Moved event listener for task button from Kanblendar init method to DOMContentLoaded handler. This change simplifies the Kanblendar class and improves modularity by placing event listening logic closer to the button initialization. Helps maintain separation of concerns and makes the code easier to manage and test.
5 lines
No EOL
243 B
JavaScript
5 lines
No EOL
243 B
JavaScript
document.addEventListener('DOMContentLoaded', () => {
|
|
const kanblendar = new Kanblendar();
|
|
const createTaskBtn = document.getElementById('createTaskBtn');
|
|
createTaskBtn.addEventListener('click', () => kanblendar.openModal());
|
|
}); |