<aside> 💡
웹 개발 종합반
선택자 = document.getElement...()
$('#id')$('.class')$('tag')$('[attribute="value"]')메서드
이벤트 처리
$('#button-id').click(function() {
// 버튼 클릭 시 실행할 코드
});
AJAX
$.ajax({
url: '<https://api.example.com/data>',
type: 'GET',
success: function(data) {
console.log(data);
},
error: function(error) {
console.error('에러 발생:', error);
}
});