diff options
| author | Leonardo Bishop <me@leonardobishop.com> | 2024-03-10 00:13:25 +0000 |
|---|---|---|
| committer | Leonardo Bishop <me@leonardobishop.com> | 2024-03-10 00:13:25 +0000 |
| commit | 9a11e0f4a38297006b89cc7bb2a60734111582e0 (patch) | |
| tree | 5ebddde79e67b659714b5dbdbfcea289f06a4ae5 /plugins | |
| parent | 817478f3cf357fc09778d9dc3cf67a667e21f042 (diff) | |
Migrate to nuxt
Diffstat (limited to 'plugins')
| -rw-r--r-- | plugins/fontawesome.ts | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/plugins/fontawesome.ts b/plugins/fontawesome.ts new file mode 100644 index 0000000..a6a1a85 --- /dev/null +++ b/plugins/fontawesome.ts @@ -0,0 +1,16 @@ +import { library, config } from '@fortawesome/fontawesome-svg-core' +import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome' +import { fas } from '@fortawesome/free-solid-svg-icons' +import { far } from '@fortawesome/free-regular-svg-icons' + +// This is important, we are going to let Nuxt worry about the CSS +config.autoAddCss = false + +// You can add your icons directly in this plugin. See other examples for how you +// can add other styles or just individual icons. +library.add(fas) +library.add(far) + +export default defineNuxtPlugin((nuxtApp) => { + nuxtApp.vueApp.component('font-awesome-icon', FontAwesomeIcon, {}) +}) |
