Skip to content

[Idea] The ability to update a visit, or be able to start a visit programmatically. #75

Description

@jmartyniak

Here is the use case:
The app is a ruby rails app, that serves HTML so no real sense of a Javascript application.

I am generating a fingerprint using fingerprintjs, which returns the result with a callback. This callback sometimes returns quickly or slowly, which seems to be based on the browser. For example in chrome it returns quickly, and on Firefox it returns slowly.

And in some cases, the visit has already been created. So when I call ahoy.configure in the callback the visit is already created and the fingerprint is never set.

A couple of thoughts:

  • whenever configure is called it updates the visit.
  • createVisit is exposed or a new helper method is created upsertVisit.

Other ideas? Am I thinking about this incorrectly?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions