Skip to content

Commit

Permalink
docs: migrate to docus (#95)
Browse files Browse the repository at this point in the history
* docs: migrate to docus

* docs: update social card
  • Loading branch information
ricardogobbosouza authored Aug 4, 2023
1 parent 43aaf30 commit e35559f
Show file tree
Hide file tree
Showing 25 changed files with 7,171 additions and 438 deletions.
1 change: 1 addition & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ coverage
dist
sw.*
.env
.output
2 changes: 2 additions & 0 deletions docs/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
shamefully-hoist=true
strict-peer-dependencies=false
27 changes: 0 additions & 27 deletions docs/README.md

This file was deleted.

14 changes: 14 additions & 0 deletions docs/app.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
export default defineAppConfig({
docus: {
title: 'Nuxt Google Fonts',
description: 'Add Google Fonts to your Nuxt application in seconds.',
image: '/social-card.png',
socials: {
twitter: 'nuxt_js',
github: 'nuxt-modules/google-fonts'
},
header: {
logo: true
}
}
})
21 changes: 15 additions & 6 deletions docs/static/logo-dark.svg → docs/components/Logo.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
<svg width="288" height="36" viewBox="0 0 288 36" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M43.82 28V14.112h3.164l.28 2.352a4.91 4.91 0 011.848-1.96c.821-.485 1.783-.728 2.884-.728 1.717 0 3.052.541 4.004 1.624.952 1.083 1.428 2.67 1.428 4.76V28h-3.584v-7.504c0-1.195-.243-2.11-.728-2.744-.485-.635-1.241-.952-2.268-.952-1.008 0-1.839.355-2.492 1.064-.635.71-.952 1.699-.952 2.968V28H43.82zm22.243.336c-1.736 0-3.08-.541-4.032-1.624-.933-1.083-1.4-2.67-1.4-4.76v-7.84h3.556v7.504c0 1.195.243 2.11.728 2.744.485.635 1.25.952 2.296.952.99 0 1.802-.355 2.436-1.064.653-.71.98-1.699.98-2.968v-7.168h3.584V28h-3.164l-.28-2.352a4.857 4.857 0 01-1.876 1.96c-.803.485-1.745.728-2.828.728zM76.574 28l5.04-6.944-5.04-6.944h3.836l3.528 4.928 3.5-4.928h3.864l-5.068 6.944L91.302 28h-3.864l-3.5-4.928L80.41 28h-3.836zm23.2 0c-1.456 0-2.623-.355-3.5-1.064-.878-.71-1.316-1.97-1.316-3.78v-6.048h-2.38v-2.996h2.38l.42-3.724h3.164v3.724h3.752v2.996h-3.752v6.076c0 .672.14 1.139.42 1.4.298.243.802.364 1.512.364h1.736V28h-2.436zm4.421 3.108l7-24.864h3.5l-7.028 24.864h-3.472z" fill="#fff"/>
<path d="M123.036 23.856a7.494 7.494 0 01-1.876-.224l-1.036 1.036c.317.168.747.308 1.288.42.541.112 1.419.224 2.632.336 1.848.168 3.192.607 4.032 1.316.84.71 1.26 1.69 1.26 2.94a4.36 4.36 0 01-.672 2.324c-.448.747-1.139 1.344-2.072 1.792-.933.467-2.128.7-3.584.7-1.979 0-3.575-.373-4.788-1.12-1.213-.728-1.82-1.83-1.82-3.304 0-1.25.607-2.333 1.82-3.248a6.812 6.812 0 01-.98-.532 5.549 5.549 0 01-.7-.588v-.644l2.436-2.576c-1.083-.952-1.624-2.175-1.624-3.668 0-.933.224-1.783.672-2.548.467-.765 1.12-1.372 1.96-1.82.84-.448 1.857-.672 3.052-.672.784 0 1.512.112 2.184.336h5.264v2.184l-2.38.168c.373.71.56 1.493.56 2.352a4.95 4.95 0 01-.672 2.548c-.448.765-1.101 1.372-1.96 1.82-.84.448-1.839.672-2.996.672zm0-2.744c.728 0 1.325-.196 1.792-.588.485-.392.728-.952.728-1.68s-.243-1.288-.728-1.68c-.467-.392-1.064-.588-1.792-.588-.765 0-1.381.196-1.848.588-.467.392-.7.952-.7 1.68s.233 1.288.7 1.68c.467.392 1.083.588 1.848.588zm-3.36 8.596c0 .69.317 1.204.952 1.54.653.355 1.447.532 2.38.532.896 0 1.624-.187 2.184-.56.56-.355.84-.84.84-1.456 0-.504-.187-.924-.56-1.26-.355-.336-1.073-.541-2.156-.616a22.236 22.236 0 01-2.128-.252c-.541.299-.933.625-1.176.98a2.021 2.021 0 00-.336 1.092zm19.538-1.372c-1.344 0-2.557-.308-3.64-.924a6.952 6.952 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.318-2.697.952-3.78a6.892 6.892 0 012.548-2.576c1.083-.616 2.296-.924 3.64-.924 1.326 0 2.52.308 3.584.924a6.626 6.626 0 012.548 2.576c.635 1.083.952 2.343.952 3.78 0 1.437-.317 2.707-.952 3.808a6.68 6.68 0 01-2.548 2.548c-1.082.616-2.286.924-3.612.924zm0-3.108c.934 0 1.746-.345 2.436-1.036.691-.71 1.036-1.755 1.036-3.136 0-1.381-.345-2.417-1.036-3.108-.69-.71-1.493-1.064-2.408-1.064-.952 0-1.773.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.691.69 1.503 1.036 2.436 1.036zm16.981 3.108c-1.344 0-2.557-.308-3.64-.924a6.952 6.952 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.317-2.697.952-3.78a6.892 6.892 0 012.548-2.576c1.083-.616 2.296-.924 3.64-.924 1.325 0 2.52.308 3.584.924a6.626 6.626 0 012.548 2.576c.635 1.083.952 2.343.952 3.78 0 1.437-.317 2.707-.952 3.808a6.68 6.68 0 01-2.548 2.548c-1.083.616-2.287.924-3.612.924zm0-3.108c.933 0 1.745-.345 2.436-1.036.691-.71 1.036-1.755 1.036-3.136 0-1.381-.345-2.417-1.036-3.108-.691-.71-1.493-1.064-2.408-1.064-.952 0-1.773.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.691.69 1.503 1.036 2.436 1.036zm15.321-1.372a7.494 7.494 0 01-1.876-.224l-1.036 1.036c.318.168.747.308 1.288.42.542.112 1.419.224 2.632.336 1.848.168 3.192.607 4.032 1.316.84.71 1.26 1.69 1.26 2.94a4.36 4.36 0 01-.672 2.324c-.448.747-1.138 1.344-2.072 1.792-.933.467-2.128.7-3.584.7-1.978 0-3.574-.373-4.788-1.12-1.213-.728-1.82-1.83-1.82-3.304 0-1.25.607-2.333 1.82-3.248a6.812 6.812 0 01-.98-.532 5.62 5.62 0 01-.7-.588v-.644l2.436-2.576c-1.082-.952-1.624-2.175-1.624-3.668 0-.933.224-1.783.672-2.548.467-.765 1.12-1.372 1.96-1.82.84-.448 1.858-.672 3.052-.672.784 0 1.512.112 2.184.336h5.264v2.184l-2.38.168c.374.71.56 1.493.56 2.352a4.95 4.95 0 01-.672 2.548c-.448.765-1.101 1.372-1.96 1.82-.84.448-1.838.672-2.996.672zm0-2.744c.728 0 1.326-.196 1.792-.588.486-.392.728-.952.728-1.68s-.242-1.288-.728-1.68c-.466-.392-1.064-.588-1.792-.588-.765 0-1.381.196-1.848.588-.466.392-.7.952-.7 1.68s.234 1.288.7 1.68c.467.392 1.083.588 1.848.588zm-3.36 8.596c0 .69.318 1.204.952 1.54.654.355 1.447.532 2.38.532.896 0 1.624-.187 2.184-.56.56-.355.84-.84.84-1.456 0-.504-.186-.924-.56-1.26-.354-.336-1.073-.541-2.156-.616a22.275 22.275 0 01-2.128-.252c-.541.299-.933.625-1.176.98a2.021 2.021 0 00-.336 1.092zM181.578 28V7.84h3.584V28h-3.584zm13.994.336c-1.4 0-2.641-.299-3.724-.896a6.482 6.482 0 01-2.548-2.52c-.616-1.083-.924-2.333-.924-3.752 0-1.437.299-2.716.896-3.836.616-1.12 1.456-1.988 2.52-2.604 1.083-.635 2.352-.952 3.808-.952 1.363 0 2.567.299 3.612.896a6.312 6.312 0 012.436 2.464c.597 1.027.896 2.175.896 3.444 0 .205-.009.42-.028.644 0 .224-.009.457-.028.7h-10.556c.075 1.083.448 1.932 1.12 2.548.691.616 1.521.924 2.492.924.728 0 1.335-.159 1.82-.476a3.1 3.1 0 001.12-1.288h3.64c-.261.877-.7 1.68-1.316 2.408a6.325 6.325 0 01-2.24 1.68c-.877.41-1.876.616-2.996.616zm.028-11.648c-.877 0-1.652.252-2.324.756-.672.485-1.101 1.232-1.288 2.24h6.916c-.056-.915-.392-1.643-1.008-2.184-.616-.541-1.381-.812-2.296-.812zm9.65 4.704v-2.996h11.732v2.996H205.25zM220.968 28V17.108h-1.904v-2.996h1.904v-1.624c0-1.68.42-2.875 1.26-3.584.859-.71 2.016-1.064 3.472-1.064h1.54v3.052h-.98c-.616 0-1.055.121-1.316.364-.261.243-.392.653-.392 1.232v1.624h2.996v2.996h-2.996V28h-3.584zm15.536.336c-1.344 0-2.558-.308-3.64-.924a6.945 6.945 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.317-2.697.952-3.78a6.884 6.884 0 012.548-2.576c1.082-.616 2.296-.924 3.64-.924 1.325 0 2.52.308 3.584.924a6.632 6.632 0 012.548 2.576c.634 1.083.952 2.343.952 3.78 0 1.437-.318 2.707-.952 3.808a6.686 6.686 0 01-2.548 2.548c-1.083.616-2.287.924-3.612.924zm0-3.108c.933 0 1.745-.345 2.436-1.036.69-.71 1.036-1.755 1.036-3.136 0-1.381-.346-2.417-1.036-3.108-.691-.71-1.494-1.064-2.408-1.064-.952 0-1.774.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.69.69 1.502 1.036 2.436 1.036zM246.82 28V14.112h3.164l.28 2.352a4.907 4.907 0 011.848-1.96c.821-.485 1.783-.728 2.884-.728 1.717 0 3.052.541 4.004 1.624.952 1.083 1.428 2.67 1.428 4.76V28h-3.584v-7.504c0-1.195-.243-2.11-.728-2.744-.485-.635-1.241-.952-2.268-.952-1.008 0-1.839.355-2.492 1.064-.635.71-.952 1.699-.952 2.968V28h-3.584zm23.223 0c-1.456 0-2.623-.355-3.5-1.064-.877-.71-1.316-1.97-1.316-3.78v-6.048h-2.38v-2.996h2.38l.42-3.724h3.164v3.724h3.752v2.996h-3.752v6.076c0 .672.14 1.139.42 1.4.299.243.803.364 1.512.364h1.736V28h-2.436zm11.337.336c-1.232 0-2.314-.196-3.248-.588-.933-.41-1.68-.97-2.24-1.68a4.823 4.823 0 01-1.008-2.464h3.612c.112.541.411 1.008.896 1.4.504.373 1.148.56 1.932.56s1.354-.159 1.708-.476c.374-.317.56-.681.56-1.092 0-.597-.261-.999-.784-1.204-.522-.224-1.25-.439-2.184-.644a23.9 23.9 0 01-1.82-.476 9.359 9.359 0 01-1.708-.7 3.965 3.965 0 01-1.232-1.12c-.317-.467-.476-1.036-.476-1.708 0-1.232.486-2.268 1.456-3.108.99-.84 2.371-1.26 4.144-1.26 1.643 0 2.95.383 3.92 1.148.99.765 1.578 1.82 1.764 3.164h-3.388c-.205-1.027-.98-1.54-2.324-1.54-.672 0-1.194.13-1.568.392-.354.261-.532.588-.532.98 0 .41.271.737.812.98.542.243 1.26.467 2.156.672.971.224 1.858.476 2.66.756.822.261 1.475.663 1.96 1.204.486.523.728 1.279.728 2.268a3.895 3.895 0 01-.672 2.324c-.466.69-1.138 1.232-2.016 1.624-.877.392-1.913.588-3.108.588z" fill="#1A73E8"/>
<rect y="2" width="32" height="32" rx="3.84" fill="#1A73E8"/><path d="M11.467 10.267h2.115v15.466h-2.115V10.267z" fill="#fff"/>
<path d="M11.467 12.238v-1.971h9.066v1.97h-9.066zM13.582 19.213v-1.971h6.196v1.971h-6.196z" fill="#fff"/>
</svg>
<template>
<svg width="288" height="36" viewBox="0 0 288 36" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M43.82 28V14.112h3.164l.28 2.352a4.91 4.91 0 011.848-1.96c.821-.485 1.783-.728 2.884-.728 1.717 0 3.052.541 4.004 1.624.952 1.083 1.428 2.67 1.428 4.76V28h-3.584v-7.504c0-1.195-.243-2.11-.728-2.744-.485-.635-1.241-.952-2.268-.952-1.008 0-1.839.355-2.492 1.064-.635.71-.952 1.699-.952 2.968V28H43.82zm22.243.336c-1.736 0-3.08-.541-4.032-1.624-.933-1.083-1.4-2.67-1.4-4.76v-7.84h3.556v7.504c0 1.195.243 2.11.728 2.744.485.635 1.25.952 2.296.952.99 0 1.802-.355 2.436-1.064.653-.71.98-1.699.98-2.968v-7.168h3.584V28h-3.164l-.28-2.352a4.857 4.857 0 01-1.876 1.96c-.803.485-1.745.728-2.828.728zM76.574 28l5.04-6.944-5.04-6.944h3.836l3.528 4.928 3.5-4.928h3.864l-5.068 6.944L91.302 28h-3.864l-3.5-4.928L80.41 28h-3.836zm23.2 0c-1.456 0-2.623-.355-3.5-1.064-.878-.71-1.316-1.97-1.316-3.78v-6.048h-2.38v-2.996h2.38l.42-3.724h3.164v3.724h3.752v2.996h-3.752v6.076c0 .672.14 1.139.42 1.4.298.243.802.364 1.512.364h1.736V28h-2.436zm4.421 3.108l7-24.864h3.5l-7.028 24.864h-3.472z"
fill="currentColor"
/>
<path
d="M123.036 23.856a7.494 7.494 0 01-1.876-.224l-1.036 1.036c.317.168.747.308 1.288.42.541.112 1.419.224 2.632.336 1.848.168 3.192.607 4.032 1.316.84.71 1.26 1.69 1.26 2.94a4.36 4.36 0 01-.672 2.324c-.448.747-1.139 1.344-2.072 1.792-.933.467-2.128.7-3.584.7-1.979 0-3.575-.373-4.788-1.12-1.213-.728-1.82-1.83-1.82-3.304 0-1.25.607-2.333 1.82-3.248a6.812 6.812 0 01-.98-.532 5.549 5.549 0 01-.7-.588v-.644l2.436-2.576c-1.083-.952-1.624-2.175-1.624-3.668 0-.933.224-1.783.672-2.548.467-.765 1.12-1.372 1.96-1.82.84-.448 1.857-.672 3.052-.672.784 0 1.512.112 2.184.336h5.264v2.184l-2.38.168c.373.71.56 1.493.56 2.352a4.95 4.95 0 01-.672 2.548c-.448.765-1.101 1.372-1.96 1.82-.84.448-1.839.672-2.996.672zm0-2.744c.728 0 1.325-.196 1.792-.588.485-.392.728-.952.728-1.68s-.243-1.288-.728-1.68c-.467-.392-1.064-.588-1.792-.588-.765 0-1.381.196-1.848.588-.467.392-.7.952-.7 1.68s.233 1.288.7 1.68c.467.392 1.083.588 1.848.588zm-3.36 8.596c0 .69.317 1.204.952 1.54.653.355 1.447.532 2.38.532.896 0 1.624-.187 2.184-.56.56-.355.84-.84.84-1.456 0-.504-.187-.924-.56-1.26-.355-.336-1.073-.541-2.156-.616a22.236 22.236 0 01-2.128-.252c-.541.299-.933.625-1.176.98a2.021 2.021 0 00-.336 1.092zm19.538-1.372c-1.344 0-2.557-.308-3.64-.924a6.952 6.952 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.318-2.697.952-3.78a6.892 6.892 0 012.548-2.576c1.083-.616 2.296-.924 3.64-.924 1.326 0 2.52.308 3.584.924a6.626 6.626 0 012.548 2.576c.635 1.083.952 2.343.952 3.78 0 1.437-.317 2.707-.952 3.808a6.68 6.68 0 01-2.548 2.548c-1.082.616-2.286.924-3.612.924zm0-3.108c.934 0 1.746-.345 2.436-1.036.691-.71 1.036-1.755 1.036-3.136 0-1.381-.345-2.417-1.036-3.108-.69-.71-1.493-1.064-2.408-1.064-.952 0-1.773.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.691.69 1.503 1.036 2.436 1.036zm16.981 3.108c-1.344 0-2.557-.308-3.64-.924a6.952 6.952 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.317-2.697.952-3.78a6.892 6.892 0 012.548-2.576c1.083-.616 2.296-.924 3.64-.924 1.325 0 2.52.308 3.584.924a6.626 6.626 0 012.548 2.576c.635 1.083.952 2.343.952 3.78 0 1.437-.317 2.707-.952 3.808a6.68 6.68 0 01-2.548 2.548c-1.083.616-2.287.924-3.612.924zm0-3.108c.933 0 1.745-.345 2.436-1.036.691-.71 1.036-1.755 1.036-3.136 0-1.381-.345-2.417-1.036-3.108-.691-.71-1.493-1.064-2.408-1.064-.952 0-1.773.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.691.69 1.503 1.036 2.436 1.036zm15.321-1.372a7.494 7.494 0 01-1.876-.224l-1.036 1.036c.318.168.747.308 1.288.42.542.112 1.419.224 2.632.336 1.848.168 3.192.607 4.032 1.316.84.71 1.26 1.69 1.26 2.94a4.36 4.36 0 01-.672 2.324c-.448.747-1.138 1.344-2.072 1.792-.933.467-2.128.7-3.584.7-1.978 0-3.574-.373-4.788-1.12-1.213-.728-1.82-1.83-1.82-3.304 0-1.25.607-2.333 1.82-3.248a6.812 6.812 0 01-.98-.532 5.62 5.62 0 01-.7-.588v-.644l2.436-2.576c-1.082-.952-1.624-2.175-1.624-3.668 0-.933.224-1.783.672-2.548.467-.765 1.12-1.372 1.96-1.82.84-.448 1.858-.672 3.052-.672.784 0 1.512.112 2.184.336h5.264v2.184l-2.38.168c.374.71.56 1.493.56 2.352a4.95 4.95 0 01-.672 2.548c-.448.765-1.101 1.372-1.96 1.82-.84.448-1.838.672-2.996.672zm0-2.744c.728 0 1.326-.196 1.792-.588.486-.392.728-.952.728-1.68s-.242-1.288-.728-1.68c-.466-.392-1.064-.588-1.792-.588-.765 0-1.381.196-1.848.588-.466.392-.7.952-.7 1.68s.234 1.288.7 1.68c.467.392 1.083.588 1.848.588zm-3.36 8.596c0 .69.318 1.204.952 1.54.654.355 1.447.532 2.38.532.896 0 1.624-.187 2.184-.56.56-.355.84-.84.84-1.456 0-.504-.186-.924-.56-1.26-.354-.336-1.073-.541-2.156-.616a22.275 22.275 0 01-2.128-.252c-.541.299-.933.625-1.176.98a2.021 2.021 0 00-.336 1.092zM181.578 28V7.84h3.584V28h-3.584zm13.994.336c-1.4 0-2.641-.299-3.724-.896a6.482 6.482 0 01-2.548-2.52c-.616-1.083-.924-2.333-.924-3.752 0-1.437.299-2.716.896-3.836.616-1.12 1.456-1.988 2.52-2.604 1.083-.635 2.352-.952 3.808-.952 1.363 0 2.567.299 3.612.896a6.312 6.312 0 012.436 2.464c.597 1.027.896 2.175.896 3.444 0 .205-.009.42-.028.644 0 .224-.009.457-.028.7h-10.556c.075 1.083.448 1.932 1.12 2.548.691.616 1.521.924 2.492.924.728 0 1.335-.159 1.82-.476a3.1 3.1 0 001.12-1.288h3.64c-.261.877-.7 1.68-1.316 2.408a6.325 6.325 0 01-2.24 1.68c-.877.41-1.876.616-2.996.616zm.028-11.648c-.877 0-1.652.252-2.324.756-.672.485-1.101 1.232-1.288 2.24h6.916c-.056-.915-.392-1.643-1.008-2.184-.616-.541-1.381-.812-2.296-.812zm9.65 4.704v-2.996h11.732v2.996H205.25zM220.968 28V17.108h-1.904v-2.996h1.904v-1.624c0-1.68.42-2.875 1.26-3.584.859-.71 2.016-1.064 3.472-1.064h1.54v3.052h-.98c-.616 0-1.055.121-1.316.364-.261.243-.392.653-.392 1.232v1.624h2.996v2.996h-2.996V28h-3.584zm15.536.336c-1.344 0-2.558-.308-3.64-.924a6.945 6.945 0 01-2.548-2.548c-.616-1.101-.924-2.37-.924-3.808 0-1.437.317-2.697.952-3.78a6.884 6.884 0 012.548-2.576c1.082-.616 2.296-.924 3.64-.924 1.325 0 2.52.308 3.584.924a6.632 6.632 0 012.548 2.576c.634 1.083.952 2.343.952 3.78 0 1.437-.318 2.707-.952 3.808a6.686 6.686 0 01-2.548 2.548c-1.083.616-2.287.924-3.612.924zm0-3.108c.933 0 1.745-.345 2.436-1.036.69-.71 1.036-1.755 1.036-3.136 0-1.381-.346-2.417-1.036-3.108-.691-.71-1.494-1.064-2.408-1.064-.952 0-1.774.355-2.464 1.064-.672.69-1.008 1.727-1.008 3.108s.336 2.427 1.008 3.136c.69.69 1.502 1.036 2.436 1.036zM246.82 28V14.112h3.164l.28 2.352a4.907 4.907 0 011.848-1.96c.821-.485 1.783-.728 2.884-.728 1.717 0 3.052.541 4.004 1.624.952 1.083 1.428 2.67 1.428 4.76V28h-3.584v-7.504c0-1.195-.243-2.11-.728-2.744-.485-.635-1.241-.952-2.268-.952-1.008 0-1.839.355-2.492 1.064-.635.71-.952 1.699-.952 2.968V28h-3.584zm23.223 0c-1.456 0-2.623-.355-3.5-1.064-.877-.71-1.316-1.97-1.316-3.78v-6.048h-2.38v-2.996h2.38l.42-3.724h3.164v3.724h3.752v2.996h-3.752v6.076c0 .672.14 1.139.42 1.4.299.243.803.364 1.512.364h1.736V28h-2.436zm11.337.336c-1.232 0-2.314-.196-3.248-.588-.933-.41-1.68-.97-2.24-1.68a4.823 4.823 0 01-1.008-2.464h3.612c.112.541.411 1.008.896 1.4.504.373 1.148.56 1.932.56s1.354-.159 1.708-.476c.374-.317.56-.681.56-1.092 0-.597-.261-.999-.784-1.204-.522-.224-1.25-.439-2.184-.644a23.9 23.9 0 01-1.82-.476 9.359 9.359 0 01-1.708-.7 3.965 3.965 0 01-1.232-1.12c-.317-.467-.476-1.036-.476-1.708 0-1.232.486-2.268 1.456-3.108.99-.84 2.371-1.26 4.144-1.26 1.643 0 2.95.383 3.92 1.148.99.765 1.578 1.82 1.764 3.164h-3.388c-.205-1.027-.98-1.54-2.324-1.54-.672 0-1.194.13-1.568.392-.354.261-.532.588-.532.98 0 .41.271.737.812.98.542.243 1.26.467 2.156.672.971.224 1.858.476 2.66.756.822.261 1.475.663 1.96 1.204.486.523.728 1.279.728 2.268a3.895 3.895 0 01-.672 2.324c-.466.69-1.138 1.232-2.016 1.624-.877.392-1.913.588-3.108.588z"
fill="#1A73E8"
/>
<rect y="2" width="32" height="32" rx="3.84" fill="#1A73E8" />
<path d="M11.467 10.267h2.115v15.466h-2.115V10.267z" fill="#fff" />
<path d="M11.467 12.238v-1.971h9.066v1.97h-9.066zM13.582 19.213v-1.971h6.196v1.971h-6.196z" fill="#fff" />
</svg>
</template>
37 changes: 37 additions & 0 deletions docs/content/0.index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
title: Google Fonts for Nuxt
navigation: false
layout: page
---

::block-hero
---
cta:
- Get Started
- /getting-started/setup
secondary:
- Star on GitHub →
- https://github.com/nuxt-modules/google-fonts
snippet: npm i -D @nuxtjs/google-fonts
---

#title
Nuxt [Google Fonts]{style="color: var(--color-primary-500)"}

#description
Welcome to [@nuxtjs/google-fonts](https://github.com/nuxt-modules/google-fonts) module documentation to help you set up [Google Fonts](https://fonts.google.com/) in your [Nuxt](https://nuxt.com) application in seconds.

#extra
::list
- Nuxt 3 ready
- TypeScript support
- Specify fonts by name/variant
- Parse head links to Google Fonts
- Creates only an external link to Google Fonts
- Support CSS API v2
- Add dns-prefetch
- Add preconnect
- Add preload
- Download css/fonts to local project (No need external resources)
- Encode fonts to base64
::
74 changes: 74 additions & 0 deletions docs/content/1.getting-started/1.setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# Setup

Using Google Fonts in your Nuxt project

## Installation

1. Install `@nuxtjs/google-fonts` dependency to your project:

::code-group

```bash [yarn]
yarn add -D @nuxtjs/google-fonts
```

```bash [npm]
npm install -D @nuxtjs/google-fonts
```

```sh [pnpm]
pnpm i -D @nuxtjs/google-fonts
```

::

2. Add it to your `modules` section in your `nuxt.config`:

::code-group
```ts [nuxt.config (Nuxt 3)]
export default defineNuxtConfig({
modules: ['@nuxtjs/google-fonts']
})
```

```ts [nuxt.config (Nuxt 2)]
export default {
buildModules: ['@nuxtjs/google-fonts']
}
```
::

## Options

You can customize the module's behavior by using the `googleFonts` property in `nuxt.config`:

```ts [nuxt.config]
export default defineNuxtConfig({
googleFonts: {
// Options
}
})
```

It is also possible to add the options directly in the module declaration:

```ts [nuxt.config]
export default defineNuxtConfig({
modules: [
['@nuxtjs/google-fonts', {
families: {
Roboto: true,
Inter: [400, 700],
'Josefin+Sans': true,
Lato: [100, 300],
Raleway: {
wght: [100, 400],
ital: [100]
},
}
}],
],
})
```

See the [module options](/getting-started/options).
Loading

0 comments on commit e35559f

Please sign in to comment.