MCPcopy Index your code
hub / github.com/jackvale/rectg / setActiveNav

Function setActiveNav

web/src/scripts/main.js:284–288  ·  view source on GitHub ↗
(id)

Source from the content-addressed store, hash-verified

282}
283
284function setActiveNav(id) {
285 document.querySelectorAll('.nav-item, .mobile-category-item').forEach((item) => {
286 item.classList.toggle('active', item.dataset.id === id);
287 });
288}
289
290function updateUrl({ sectionId, query, replace = false }) {
291 const url = new URL(window.location);

Callers 2

renderSectionFunction · 0.85
renderSearchFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected