Skip to content

Commit

Permalink
Update main.js
Browse files Browse the repository at this point in the history
  • Loading branch information
cfunkz authored Mar 23, 2024
1 parent a06a95b commit 7824e31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ document.addEventListener('DOMContentLoaded', function() {
}
});
$(document).ready(function() {
$('a.nav-link').on('click', function(clickevent) {
$('a').on('click', function(clickevent) {
clickevent.preventDefault(); // Prevent default link
var targetId = $(this).attr('href'); // Get the target section ID from the "href" of the clicked link
var offsetTop = $(targetId).offset().top; // Calculate the top offset of the target section
Expand Down

0 comments on commit 7824e31

Please sign in to comment.