Skip to content

Frequently Asked Questions

How do I collect logs?

Logging can be helpful when you run into any issues. Logs contain information about how you use our products. That data helps Regula stuff to analyze and troubleshoot the cases you may experience.

There are two ways to output logs: console or function callback.

Console

To initiate the process of logs collecting:

1. Open the Developer menu in your browser.

2. Go to the Console tab.

3. In Console, enter the following line:

localStorage.logger = 'main,wasm>console'

4. Reload the page.

5. Add the log setting to the processParam if you want to see logs from WASM:

{
  "processParam": {
    "log": true
  }
}

6. Start image processing. Logs will be displayed in Console.

Function callback

1. Import logging service from the library.

import { Logger } from '@regulaforensics/vp-frontend-document-components';

2. Set the callback function.

Logger.logListener = (log) => {
    // ...
    // do something with log
    // ...
};

3. Add the log setting to the processParam if you want to see logs from WASM:

{
  "processParam": {
    "log": true
  }
}

How to add license?

There is no need to add the license to your production environment, as domain name licensing is applied. To get your website domain licensed, contact our sales team.

How much space do the Web Components occupy?

Adding the Document Reader SDK Web Components to your website increases its size.

To find out how to calculate the resulting impact, consider the sizes of the following parts:

For assessing the sizes of the package resources, run your web application and open the browser's Developer Tools on the Network tab. For details, see the links below:

Note

To preserve local caching, on the Network tab find the Disable cache checkbox and select it. This helps to reveal the real network bandwidth, used for the resources' loading.

The resulting components' size depends on several factors:

  • The chosen module bundler (Webpack, Vite, Rollup, Parcel, etc.)
  • The selected WASM Module Type.
  • The used server-side compression method, which affects the download size of the resources when you host them yourself. For details, see the Web Components Package Resources page.