Skip to content

Commit

Permalink
Add items to sitemap
Browse files Browse the repository at this point in the history
  • Loading branch information
gocemitevski committed Jan 31, 2024
1 parent 1549ecf commit 5e00327
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/buildSitemap.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,7 @@ const municipalitiesSort = () => {

const homepage = `https://gocemitevski.github.io/sredni-ucilista-mk`;
const sitemap = data.uchilishta.map(item => `${homepage}/uchilishte/${encodeURIComponent(cleanName(transliterate(item.ime + ' ' + item.opstina)).toLowerCase())}`);
sitemap.push(`${homepage}/adresar`);
sitemap.push(`${homepage}/za-izrabotkata`);
municipalitiesSort().map(item => sitemap.push(`${homepage}/opshtina/${encodeURIComponent(cleanName(transliterate(item[0])).toLowerCase())}`));
console.log(`<?xml version="1.0" encoding="UTF-8"?><urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">${sitemap.map(el => `<url><loc>${el}</loc></url>`).join('')}</urlset>`);

0 comments on commit 5e00327

Please sign in to comment.