Skip to content

Latest commit

 

History

History
78 lines (52 loc) · 1.73 KB

File metadata and controls

78 lines (52 loc) · 1.73 KB

Naive UI

Plausible is a lightweight and open-source Google Analytics alternative. Your website data is 100% yours and the privacy of your visitors is respected.

alt text

Plausible integration for Nuxt

Setup

::code-group

pnpm add @huntersofbook/naive-ui-nuxt
yarn add @huntersofbook/naive-ui-nuxt
npm add @huntersofbook/naive-ui-nuxt

::

Nuxt Config

export default defineNuxtConfig({
  modules: [
    '@huntersofbook/naive-ui-nuxt'
  ]
})

Composables

<script setup lang="ts">
import { darkTheme } from 'naive-ui'

</script>

<template>
  <NConfigProvider :theme="darkTheme">
    <NGlobalStyle />
    <div>
      Nuxt module playground!
      <NButton>Default</NButton>
    </div>
  </NConfigProvider>
</template>

Development 💻

  • Clone this repository
  • Enable Corepack using corepack enable (use npm i -g corepack for Node.js < 16.10)
  • Install dependencies using pnpm install
  • Stub module with pnpm dev:prepare
  • Run pnpm dev to start playground in development mode

License

MIT License © 2022-PRESENT productdevbook

Thanks

Thanks to @07akioni, this project is heavily inspired by naive-ui-nuxt-demo.

Thanks to @tobiasdiez, this project is inspired by some code structure.

💚 Credits

Nuxt 3 Plugin danielroe