Open stefanofusai opened 5 months ago
I was able to make it work with my self-hosted plausible instance
Can you try
<PlausibleProvider domain={process.env.DOMAIN}
customDomain="https://analytics.placeholder.com" selfHosted={true} />
I was able to make it work with my self-hosted plausible instance
Can you try
<PlausibleProvider domain={process.env.DOMAIN} customDomain="https://analytics.placeholder.com" selfHosted={true} />
Thank you for your help, unfortunately this still doesn't work. What does your process.env.DOMAIN look like?
I have it hardcoded to my website's DNS which also matches with plausible's website dns
EDIT: I have domain without https://
I have it hardcoded to my website's DNS which also matches with plausible's website dns
EDIT: I have domain without
https://
Thank you for your help. It still seems like requests are not being sent out. I'm really not sure what I'm doing wrong
next.config.js
module.exports = withPlausibleProxy({
customDomain: process.env.PLAUSIBLE_CUSTOM_DOMAIN, // https://analytics.example.com
})(nextConfig);
layout.tsx
<head>
<PlausibleProvider
domain={process.env.PLAUSIBLE_DOMAIN} // example.com
customDomain={process.env.PLAUSIBLE_CUSTOM_DOMAIN} // https://analytics.example.com
selfHosted={true}
/>
are u sure your env variables are properly exposed/set? I did exactly the same but with hardcoded variables and it worked.
First of all, thank you for your library! Unfortunately, I can't get it to work :(
I have my site hosted at
placeholder.com
, and my Plausible instance running (selfhosted) atanalytics.placeholder.com
Unfortunately, the library tries to access thescript.js
file atplaceholder.com
, resulting in a 404, and I can't seem to change this.Here is my
next.config.js
:And here is my
layout.tsx
:What am I doing wrong? Thank you!