1.0.0 • Published 9 months ago

@hawk.so/nuxt v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

@hawk.so/nuxt

npm version License Nuxt

Hawk error tracker integration for Nuxt app

Features

  • 😋 Effortless installation
  • 🦅 Track errors seamlessly across your Nuxt app
  • 💼 Composable for manually sending errors and logs
  • 💌 Sends release info with source maps

Quick Setup

Install the module with one command:

npx nuxi module add @hawk.so/nuxt

Then connect and configure to your nuxt.config.ts. Pass there an Integration Token you got from Hawk project. You can pass it directly or use .env file wich is supported by Nuxt out of the box.

export default defineNuxtConfig({
  modules: [
    '@hawk.so/nuxt'
  ],
  hawk: {
    token: process.env.HAWK_TOKEN,
  },
})

Passing additional options

You can pass user, context, beforeSend and other JS Catcher options via catcherOptions config property.

export default defineNuxtConfig({
  modules: [
    '@hawk.so/nuxt'
  ],

  hawk: {
    token: process.env.HAWK_TOKEN,
    catcherOptions: {
      context: {
        // any data you want to send with all events
        appName: 'Hawk Nuxt Playground',
      },
      // method for filtering/modifying an event to be sent
      beforeSend: (event) => {
        event.context.appVersion = '1.0.0'

        return event
      },
    },
  },
})

Contribution

1.0.0

9 months ago

0.0.7

9 months ago

0.0.6

9 months ago

0.0.4

9 months ago

0.0.3

9 months ago

0.0.2

10 months ago