Frontend

All frontend integrations on one place.

Installation

circle-info

You don't need to install @types/errorlogger-sdk.Types are shipping with SDK.

circle-info

You will get autocomplete / intellisense in JS files.

npm i errorlogger-sdk --save
circle-info

- ErrorLoggerClientOptions

  • Short summary of ErrorLoggerClientOptions:

Property

Type

Description

dsn

string

Represents an api key which authorizes you with API

environment

string

Represents in which environment you want to log errors. Valid options (development | production)

data

object

Additional data you want to log. EX. Network connection

VueJS

circle-info

Create.env file and add your DSN (Data Source Name).

.env
VUE_APP_ERRORLOGGER_DSN=<DSN-HERE>
circle-info

Go to main.js and add following lines.

main.js
import { ErrorLoggerClient } from 'errorlogger-sdk/build/client/ErrorLoggerClient'

new ErrorLoggerClient({
  dsn: process.env.VUE_APP_ERRORLOGGER_DSN,
  environment: 'production'
});
circle-check

React

circle-info

Create.env file and add your DSN (Data Source Name).

circle-info

Go to index.js and add following lines.

circle-check

Angular

circle-info

Go tosrc/environments/environment.[prod].ts and add DSN to environvment

circle-info

Go to app.module.ts and add following lines.

circle-check

Last updated