Skip to content

Commit

Permalink
chore: Improve lighthouse score (#86)
Browse files Browse the repository at this point in the history
* fix(seo): support configurable base url

* fix: improve Twitter card accessibility

* remove empty fr content

* chore: use docus url from settings

Co-authored-by: Sébastien Chopin <seb@nuxtjs.com>
  • Loading branch information
farnabaz and atinux authored Feb 22, 2021
1 parent 81347d1 commit 31654a0
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions docs/components/global/Tweet.vue
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<template>
<div class="tweet">
<blockquote class="tweet">
<div class="author flex mb-4">
<a :href="profileUrl" target="_blank" rel="noopener noreferrer">
<img :src="avatar" class="w-6 h-6 rounded-full" :class="{'h-12 w-12': layout === 'tweet'}" />
<img :src="avatar" :alt="name" class="w-6 h-6 rounded-full" :class="{'h-12 w-12': layout === 'tweet'}" />
</a>
<div class="ml-2 flex-1">
<a :href="profileUrl" target="_blank" rel="noopener noreferrer">
Expand All @@ -19,7 +19,7 @@
</template>
</div>
<a v-if="layout === 'tweet'" :href="tweetUrl" target="_blank" rel="noopener noreferrer">
<IconTwitter class="text-blue-500" />
<IconTwitter title="View on Twitter" role="img" class="text-blue-500" />
</a>
</div>
<div class="content">
Expand All @@ -34,7 +34,7 @@
{{ $d(createdAt, "long") }}
</a>
</div>
</div>
</blockquote>
</template>

<script>
Expand Down
1 change: 0 additions & 1 deletion docs/content/fr/1.index.md

This file was deleted.

1 change: 1 addition & 0 deletions theme/nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ export default docusOptions => ({
classSuffix: ''
},
i18n: {
baseUrl: ({ $docus }) => $docus?.settings?.url || '',
locales: [{
code: 'en',
iso: 'en-US',
Expand Down

1 comment on commit 31654a0

@vercel
Copy link

@vercel vercel bot commented on 31654a0 Feb 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.