File tree Expand file tree Collapse file tree 2 files changed +13
-12
lines changed Expand file tree Collapse file tree 2 files changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -7,13 +7,12 @@ import beautify from 'js-beautify';
77export default {
88
99 /**
10- * Beautify HTML and XML output
10+ * Beautify HTML output
1111 */
1212 async beautify ( eleventyConfig ) {
1313 eleventyConfig . addTransform ( 'beautify' , async function ( content ) {
1414 const types = [
1515 '.html' ,
16- '.xml' ,
1716 ] ;
1817
1918 if ( this . page . outputPath ) {
Original file line number Diff line number Diff line change 11---
22permalink: /sitemap.xml
33eleventyExcludeFromCollections: true
4+ layout: null
5+ templateEngineOverride: njk
46---
57<?xml version =" 1.0" encoding =" utf-8" ?>
68<urlset xmlns =" http://www.sitemaps.org/schemas/sitemap/0.9" >
7- {%- for page in collections .all -%}
8- {%- if page .url != ' ' and page .data .sitemapIgnore != true -%}
9- <url >
10- <loc >{{ env . siteUrl }}{{ page .url | url }} </loc >
11- {%- if page .date -%} <lastmod >{{ page .date }} </lastmod >{%- endif -%}
12- {%- if page .data .changefreq -%} <changefreq >{{ page .data .changefreq }} </changefreq >{%- endif -%}
13- {%- if page .data .priority -%} <priority >{{ page .data .priority }} </priority >{%- endif -%}
14- </url >
15- {%- endif -%}
16- {%- endfor -%}
9+ {%- for page in collections .all -%}
10+ {%- if page .url != ' ' and page .data .sitemapIgnore != true -%}
11+ <url >
12+ <loc >{{ site . url }}{{ page .url | url }} </loc >
13+ {%- if page .date -%} <lastmod >{{ page .date . toISOString () }} </lastmod >{%- endif -%}
14+ {%- if page .data .changefreq -%} <changefreq >{{ page .data .changefreq }} </changefreq >{%- endif -%}
15+ {%- if page .data .priority -%} <priority >{{ page .data .priority }} </priority >{%- endif -%}
16+ </url >
17+ {%- endif -%}
18+ {%- endfor -%}
1719</urlset >
You can’t perform that action at this time.
0 commit comments