Hai i want to develop block that will GET data from API every time HTML event is occur, but i dont know how to do it with moodle best practice. The ENDPOINT is localhost/moodle/get_data.php i created this file manually and the code is return $DB->get_records_sql(QUERYHERE);
do i need to wrap get_data.php to Local plugin ? And use mustache to display data instead of getElementByID.innerHTML ?
Thx anyway.