Open feelform opened 2 years ago
We confirmed that it is currently tracking properly in the Next.js page directory. What does Next.js do?
i think some people faced same issue like me
if you want to set up Pinpoint-Node-Agent,
you should check next.config.js instrumentationHook option
and you just implement pinpoint code at instrumentation.js
// next.config.js
{
experimental: {
instrumentationHook: true,
},
}
// instrumentation.js
export async function register () {
if(process.env.NEXT_RUNTIME === "nodejs"){
const Agent = await require("pinpoint-node-agent/lib/agent")
new Agent({
...your config
})
}
}
+1