1. Install the packages

Install the browser SDK and Vue integration together.

npm install @ashkarhq/browser @ashkarhq/vue

2. Connect Ashkar to Vue

Create the client and install the Vue integration before mounting the app.

import { createApp } from "vue";
import { init } from "@ashkarhq/browser";
import { installVue } from "@ashkarhq/vue";
import App from "./App.vue";

const app = createApp(App);
export const ashkar = init({
  dsn: "https://app.ashkarhq.ir/api/v1/events",
  projectKey: "YOUR_PUBLIC_KEY",
  environment: "production",
  release: "web@1.0.0",
});

installVue(app, ashkar);
app.mount("#app");

3. Send a test error

Send this error once to make sure the project is connected correctly.

await ashkar.captureException(
  new Error("Ashkar Vue test"),
);
await ashkar.flush();

4. Check the result in Issues

Look for “Ashkar Vue test” in Issues. Future Vue failures will appear in the same project with component details.