Skip to content

Update plausible API client #7

@vitonsky

Description

@vitonsky

Hey, i just recently found analytics package https://github.com/DavidWells/analytics and as i see you implemented an plausible plugin for it.

It looks you use package plausible-tracker that is not actively maintained and have a lot of bugs, especially when used with static sites

"plausible-tracker": "^0.3.1"

Some of known bugs is

There are official plausible-tracker package, it have quite few code, but have a lot of bugs like

  • "enableAutoOutboundTracking breaks target="_blank" and probably noopener security" #12
  • uses XHR API that loses analytics on static sites with no SPA approach (like Astro does) #16
  • uses callbacks, that will not be called on localhost, that force users write code that works different locally and on production

The most bad problem is plausible-tracker is currently lost events on static sites, that makes this package is completely useless and harm for product.

I've implemented a plausible client that fix all problems https://github.com/vitonsky/plausible-client

Let's move on this solution that does work.

I actively use this solution at least in 8 my projects, there are couple static sites and it works well for me, so you may don't care about package maintenance, because I eat this food, unlike maintainers of plausible-tracker that is looks abandoned.

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