- Inserted Prerendering plugin('prerender-spa-plugin') to create HTML pages (for Google... crawler)
- Added Meta Tags (title, description and keywords)
This commit is contained in:
@@ -10,28 +10,15 @@ import { toolsext } from '@src/store/Modules/toolsext'
|
|||||||
import { Screen } from 'quasar'
|
import { Screen } from 'quasar'
|
||||||
import { CImgTitle } from '../../components/CImgTitle/index'
|
import { CImgTitle } from '../../components/CImgTitle/index'
|
||||||
import { CTitle } from '../../components/CTitle/index'
|
import { CTitle } from '../../components/CTitle/index'
|
||||||
|
import MixinsMetaTags from '../../mixins/mixin-metatags'
|
||||||
// Vue.use(VueScrollReveal, {
|
|
||||||
// class: 'v-scroll-reveal', // A CSS class applied to elements with the v-scroll-reveal directive; useful for animation overrides.
|
|
||||||
// duration: 1200,
|
|
||||||
// scale: 0.95,
|
|
||||||
// distance: '10px',
|
|
||||||
// rotate: {
|
|
||||||
// x: 0,
|
|
||||||
// y: 0,
|
|
||||||
// z: 0
|
|
||||||
// }
|
|
||||||
// // mobile: true
|
|
||||||
// })
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
name: 'CMyPage',
|
name: 'CMyPage',
|
||||||
|
mixins: [MixinsMetaTags],
|
||||||
components: { Footer, CImgTitle, CTitle }
|
components: { Footer, CImgTitle, CTitle }
|
||||||
})
|
})
|
||||||
export default class CMyPage extends Vue {
|
export default class CMyPage extends Vue {
|
||||||
@Prop({ required: true, default: '' }) public title: string
|
@Prop({ required: true, default: '' }) public title: string
|
||||||
@Prop({ required: true, default: '' }) public keywords: string
|
|
||||||
@Prop({ required: true, default: '' }) public description: string
|
|
||||||
@Prop({ required: false, default: '' }) public img: string
|
@Prop({ required: false, default: '' }) public img: string
|
||||||
@Prop({ required: false, default: '' }) public imgbackground: string
|
@Prop({ required: false, default: '' }) public imgbackground: string
|
||||||
@Prop({ required: false, default: '' }) public sizes: string
|
@Prop({ required: false, default: '' }) public sizes: string
|
||||||
@@ -39,17 +26,18 @@ export default class CMyPage extends Vue {
|
|||||||
public $t
|
public $t
|
||||||
public $q
|
public $q
|
||||||
|
|
||||||
public meta() {
|
// public metaInfo() {
|
||||||
return {
|
// return {
|
||||||
title: this.$t('msg.myAppName'),
|
// // title: this.$t('msg.myAppName'),
|
||||||
titleTemplate: (title) => `${this.title} - ${this.$t('msg.myAppName')}`,
|
// title: 'PROVA TITOLOOOOOOO!!!!!!!!!!!!!!!!!!!!**************************',
|
||||||
meta: {
|
// titleTemplate: (title) => `${this.title} - ${this.$t('msg.myAppName')}`,
|
||||||
keywords: { name: 'keywords', content: this.keywords },
|
// meta: {
|
||||||
description: { name: 'description', content: this.description },
|
// keywords: { name: 'keywords', content: this.keywords },
|
||||||
equiv: { 'http-equiv': 'Content-Type', 'content': 'text/html; charset=UTF-8' }
|
// description: { name: 'description', content: this.description },
|
||||||
}
|
// equiv: { 'http-equiv': 'Content-Type', 'content': 'text/html; charset=UTF-8' }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
public mounted() {
|
public mounted() {
|
||||||
// console.log('CMYPage title=', this.title)
|
// console.log('CMYPage title=', this.title)
|
||||||
|
|||||||
@@ -47,6 +47,12 @@ export interface IConfig {
|
|||||||
value: string
|
value: string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface IMetaTags {
|
||||||
|
title?: string
|
||||||
|
keywords?: string
|
||||||
|
description?: string
|
||||||
|
}
|
||||||
|
|
||||||
export interface IGlobalState {
|
export interface IGlobalState {
|
||||||
finishLoading: boolean
|
finishLoading: boolean
|
||||||
conta: number
|
conta: number
|
||||||
|
|||||||
@@ -660,6 +660,8 @@ namespace Actions {
|
|||||||
GlobalStore.state.finishLoading = true
|
GlobalStore.state.finishLoading = true
|
||||||
console.log('finishLoading', GlobalStore.state.finishLoading)
|
console.log('finishLoading', GlobalStore.state.finishLoading)
|
||||||
|
|
||||||
|
// document.dispatchEvent(new Event('custom-post-render-event'))
|
||||||
|
|
||||||
return true
|
return true
|
||||||
// console.log('setGlobal: END')
|
// console.log('setGlobal: END')
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import { toolsext } from './toolsext'
|
|||||||
import { translation } from './translation'
|
import { translation } from './translation'
|
||||||
import Quasar, { colors, date, Screen } from 'quasar'
|
import Quasar, { colors, date, Screen } from 'quasar'
|
||||||
import { scroll } from 'quasar'
|
import { scroll } from 'quasar'
|
||||||
|
|
||||||
const { getScrollTarget, setScrollPosition } = scroll
|
const { getScrollTarget, setScrollPosition } = scroll
|
||||||
|
|
||||||
import {
|
import {
|
||||||
@@ -2633,7 +2634,25 @@ export const tools = {
|
|||||||
return 'https://t.me/' + usertelegram
|
return 'https://t.me/' + usertelegram
|
||||||
else
|
else
|
||||||
return ''
|
return ''
|
||||||
|
},
|
||||||
|
metafunc(mythis) {
|
||||||
|
return {
|
||||||
|
title: mythis.$t('msg.myAppName'),
|
||||||
|
titleTemplate: (title) => `${mythis.mymeta.title} - ${mythis.$t('msg.myAppName')}`,
|
||||||
|
meta: {
|
||||||
|
keywords: {
|
||||||
|
name: 'keywords',
|
||||||
|
content: mythis.mymeta.keywords
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
name: 'description',
|
||||||
|
content: mythis.mymeta.description
|
||||||
|
},
|
||||||
|
equiv: { 'http-equiv': 'Content-Type', 'content': 'text/html; charset=UTF-8' }
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// getLocale() {
|
// getLocale() {
|
||||||
// if (navigator.languages && navigator.languages.length > 0) {
|
// if (navigator.languages && navigator.languages.length > 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user