@moneko/core 3.0.0-beta.85 → 3.0.0-beta.86

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/seo.js +1 -1
  2. package/package.json +1 -1
package/lib/seo.js CHANGED
@@ -1 +1 @@
1
- import{existsSync as t,mkdirSync as o,writeFileSync as r}from"fs";import{join as e}from"path";import{CONFIG as s}from"./common.js";import{routes as m}from"./routes.js";import{resolveProgramPath as i}from"./utils.js";import{outputConfig as p}from"./webpack.common.js";function c(t,o){try{r(t,o,"utf-8")}catch(t){}}export const seo=()=>{let{domain:r,nojekyll:a,path:f}=s.seo||{};if(!r)return;let n=s.routeBaseName,h=n.endsWith("/")?n:`${n}/`,l=f&&i(f)||p?.path||process.cwd();t(l)||o(l),c(e(l,"CNAME"),r),c(e(l,"robots"),`Sitemap: https://${r}${h}sitemap.txt`);let u=[];!function t(o){o.forEach(o=>{u.push(`https://${r}${h}${o.key}`),Array.isArray(o.children)&&t(o.children)})}(m),c(e(l,"sitemap.txt"),u),a&&c(e(l,".nojekyll"),"")};
1
+ import{existsSync as t,mkdirSync as o,writeFileSync as r}from"fs";import{join as e}from"path";import{CONFIG as s}from"./common.js";import{routes as m}from"./routes.js";import{resolveProgramPath as i}from"./utils.js";import{outputConfig as p}from"./webpack.common.js";function n(t,o){try{r(t,o,"utf-8")}catch(t){}}export const seo=()=>{let{domain:r,nojekyll:c,path:a}=s.seo||{};if(!r)return;let f=s.routeBaseName,h=f.endsWith("/")?f:`${f}/`,l=a&&i(a)||p?.path||process.cwd();t(l)||o(l),n(e(l,"CNAME"),r),n(e(l,"robots"),`Sitemap: https://${r}${h}sitemap.txt`);let u=[];!function t(o){o.forEach(o=>{u.push(`https://${r}${h}${o.key}`),Array.isArray(o.children)&&t(o.children)})}(m),n(e(l,"sitemap.txt"),u.join("\n")),c&&n(e(l,".nojekyll"),"")};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moneko/core",
3
- "version": "3.0.0-beta.85",
3
+ "version": "3.0.0-beta.86",
4
4
  "description": "core",
5
5
  "main": "lib/index.js",
6
6
  "type": "module",