Skip to content

Commit

Permalink
#44 set description for doc
Browse files Browse the repository at this point in the history
  • Loading branch information
hamalt committed Jul 25, 2022
1 parent 4c5b883 commit 77d5e4d
Showing 1 changed file with 47 additions and 47 deletions.
94 changes: 47 additions & 47 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Scsaver.js</title>
<title>Scsaver.js | Web page screensaver JavaScript library.</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta name="description" content>
<meta name="keywords" content>
<meta name="description" content="Scsaver.js is a JavaScript library for web page screensaver.">
<meta name="keywords" content="javascript, screensaver">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/docsify@4/lib/themes/vue.css">
<link rel="stylesheet" href="./assets/css/scsaver.css">
Expand Down Expand Up @@ -67,55 +67,55 @@ <h1>Hello, Scsaver.</h1>
// mergeNavbar: true,
maxLevel: 1,
subMaxLevel: 3,
seo: {
title: (route, frontmatter) => {
console.log(route);
// console.log(frontmatter);

// route.fileの拡張子を削除
const fileName = route.file;

// undefinedなら処理をしない
if (typeof fileName === 'undefined') return;
// console.log(fileName);

// fileNameの最後の文字3つを削除
// fileName = route.file.substring(0, fileName.length - 3);
// console.log(fileName);
// fileName = fileName.replace(/\.[^/.]+$/, "");
// console.log(fileName);
let title = "";

switch (route.path) {
case '/':
title = "Scsaver.js | Web page screensaver JavaScript library.";
break;
}

return title;
},
description: (route, frontmatter) => {
console.log(route.path);
let description = "";

switch (route.path) {
case '/':
description = "Scsaver.js is a JavaScript library for web page screensaver.";
break;
}
// if (route.path.startWith('/ja/')) return `一般的な説明`
// else return `Some default description`

return description;
},
keywords: `javascript, screensaver`,
},
// seo: {
// title: (route, frontmatter) => {
// console.log(route);
// // console.log(frontmatter);

// // route.fileの拡張子を削除
// const fileName = route.file;

// // undefinedなら処理をしない
// if (typeof fileName === 'undefined') return;
// // console.log(fileName);

// // fileNameの最後の文字3つを削除
// // fileName = route.file.substring(0, fileName.length - 3);
// // console.log(fileName);
// // fileName = fileName.replace(/\.[^/.]+$/, "");
// // console.log(fileName);
// let title = "";

// switch (route.path) {
// case '/':
// title = "Scsaver.js | Web page screensaver JavaScript library.";
// break;
// }

// return title;
// },
// description: (route, frontmatter) => {
// console.log(route.path);
// let description = "";

// switch (route.path) {
// case '/':
// description = "Scsaver.js is a JavaScript library for web page screensaver.";
// break;
// }
// // if (route.path.startWith('/ja/')) return `一般的な説明`
// // else return `Some default description`

// return description;
// },
// keywords: `javascript, screensaver`,
// },
}
</script>
<!-- Docsify v4 -->
<script src="//cdn.jsdelivr.net/npm/docsify@4"></script>
<script src="//cdn.jsdelivr.net/npm/docsify-pagination/dist/docsify-pagination.min.js"></script>
<script src="./assets/js/dcsify.plugin.seo.js"></script>
<!-- <script src="./assets/js/dcsify.plugin.seo.js"></script> -->

<script>
const option = {
Expand Down

0 comments on commit 77d5e4d

Please sign in to comment.