🔍 Improving SEO

This commit is contained in:
Liyas Thomas
2020-06-21 11:26:19 +05:30
parent fe9c08e92a
commit a38ef9e29e
7 changed files with 28 additions and 16 deletions

View File

@@ -59,7 +59,7 @@
<i class="material-icons">settings</i> <i class="material-icons">settings</i>
</nuxt-link> </nuxt-link>
</nav> </nav>
<div v-if="$route.path === '/'"> <div v-if="$route.path == '/'">
<nav class="secondary-nav"> <nav class="secondary-nav">
<ul> <ul>
<li> <li>
@@ -80,7 +80,7 @@
</ul> </ul>
</nav> </nav>
</div> </div>
<div v-else-if="$route.path === '/realtime'"> <div v-else-if="$route.path.includes('/realtime')">
<nav class="secondary-nav"> <nav class="secondary-nav">
<ul> <ul>
<li> <li>
@@ -96,7 +96,7 @@
</ul> </ul>
</nav> </nav>
</div> </div>
<div v-else-if="$route.path === '/graphql'"> <div v-else-if="$route.path.includes('/graphql')">
<nav class="secondary-nav"> <nav class="secondary-nav">
<ul> <ul>
<li> <li>
@@ -122,7 +122,7 @@
</ul> </ul>
</nav> </nav>
</div> </div>
<div v-else-if="$route.path === '/doc'"> <div v-else-if="$route.path.includes('/doc')">
<nav class="secondary-nav"> <nav class="secondary-nav">
<ul> <ul>
<li> <li>
@@ -138,7 +138,7 @@
</ul> </ul>
</nav> </nav>
</div> </div>
<div v-else-if="$route.path === '/settings'"> <div v-else-if="$route.path.includes('/settings')">
<nav class="secondary-nav"> <nav class="secondary-nav">
<ul> <ul>
<li> <li>

View File

@@ -36,7 +36,7 @@ export default {
host: "0.0.0.0", // default: localhost host: "0.0.0.0", // default: localhost
}, },
head: { head: {
title: `${options.name} \u2022 ${options.shortDescription}`, title: `${options.name} ${options.shortDescription}`,
meta: [ meta: [
{ {
name: "keywords", name: "keywords",
@@ -49,7 +49,7 @@ export default {
}, },
{ {
itemprop: "name", itemprop: "name",
content: `${options.name} \u2022 ${options.shortDescription}`, content: `${options.name} ${options.shortDescription}`,
}, },
{ {
itemprop: "description", itemprop: "description",

View File

@@ -310,14 +310,12 @@ export default {
"pw-section": () => import("~/components/layout/section"), "pw-section": () => import("~/components/layout/section"),
Editor: AceEditor, Editor: AceEditor,
}, },
data() { data() {
return { return {
collectionJSON: "[]", collectionJSON: "[]",
items: [], items: [],
} }
}, },
methods: { methods: {
uploadCollection() { uploadCollection() {
this.rawInput = true this.rawInput = true
@@ -352,5 +350,10 @@ export default {
} }
}, },
}, },
head() {
return {
title: `Documentation • ${this.$store.state.name}`,
}
},
} }
</script> </script>

View File

@@ -381,7 +381,6 @@ export default {
}, },
} }
}, },
computed: { computed: {
url: { url: {
get() { get() {
@@ -445,7 +444,6 @@ export default {
mounted() { mounted() {
if (this.$store.state.gql.schemaIntrospection && this.$store.state.gql.schema) { if (this.$store.state.gql.schemaIntrospection && this.$store.state.gql.schema) {
const gqlSchema = gql.buildClientSchema(JSON.parse(this.$store.state.gql.schemaIntrospection)) const gqlSchema = gql.buildClientSchema(JSON.parse(this.$store.state.gql.schemaIntrospection))
this.getDocsFromSchema(gqlSchema) this.getDocsFromSchema(gqlSchema)
} }
}, },
@@ -744,5 +742,10 @@ export default {
}) })
}, },
}, },
head() {
return {
title: `GraphQL • ${this.$store.state.name}`,
}
},
} }
</script> </script>

View File

@@ -33,5 +33,10 @@ export default {
socketio: () => import("~/components/realtime/socketio"), socketio: () => import("~/components/realtime/socketio"),
mqtt: () => import("~/components/realtime/mqtt"), mqtt: () => import("~/components/realtime/mqtt"),
}, },
head() {
return {
title: `Realtime • ${this.$store.state.name}`,
}
},
} }
</script> </script>

View File

@@ -219,7 +219,6 @@ export default {
login: () => import("~/components/firebase/login"), login: () => import("~/components/firebase/login"),
logout: () => import("~/components/firebase/logout"), logout: () => import("~/components/firebase/logout"),
}, },
data() { data() {
return { return {
// NOTE:: You need to first set the CSS for your theme in /assets/css/themes.scss // NOTE:: You need to first set the CSS for your theme in /assets/css/themes.scss
@@ -327,7 +326,6 @@ export default {
fb, fb,
} }
}, },
watch: { watch: {
proxySettings: { proxySettings: {
deep: true, deep: true,
@@ -337,7 +335,6 @@ export default {
}, },
}, },
}, },
methods: { methods: {
applyTheme({ class: name, color, aceEditor }) { applyTheme({ class: name, color, aceEditor }) {
this.applySetting("THEME_CLASS", name) this.applySetting("THEME_CLASS", name)
@@ -409,12 +406,10 @@ export default {
} }
}, },
}, },
beforeMount() { beforeMount() {
this.settings.THEME_CLASS = document.documentElement.className this.settings.THEME_CLASS = document.documentElement.className
this.settings.THEME_COLOR = this.getActiveColor() this.settings.THEME_COLOR = this.getActiveColor()
}, },
computed: { computed: {
proxySettings() { proxySettings() {
return { return {
@@ -423,5 +418,10 @@ export default {
} }
}, },
}, },
head() {
return {
title: `Settings • ${this.$store.state.name}`,
}
},
} }
</script> </script>

View File

@@ -47,4 +47,5 @@ export default () => ({
clientId: "", clientId: "",
scope: "", scope: "",
}, },
name: "Postwoman",
}) })