Skip to content

Commit

Permalink
feat: add nr agent id config (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
qin-guan authored Jan 30, 2024
1 parent 6d14644 commit 731d2e0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ export default defineNuxtConfig({
},

newRelic: {
agentId: '' || process.env.NUXT_PUBLIC_NEW_RELIC_AGENT_ID,
applicationId: '' || process.env.NUXT_PUBLIC_NEW_RELIC_APPLICATION_ID,
},
},
Expand Down
2 changes: 1 addition & 1 deletion plugins/new-relic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default defineNuxtPlugin(() => {
const options = {
init: { distributed_tracing: { enabled: true }, privacy: { cookies_enabled: true }, ajax: { deny_list: ['bam.eu01.nr-data.net'] } },
info: { beacon: 'bam.eu01.nr-data.net', errorBeacon: 'bam.eu01.nr-data.net', licenseKey: 'NRJS-1b1f41c1d6baafe183c', applicationID: config.newRelic.applicationId, sa: 1 },
loader_config: { accountID: '4337277', trustKey: '4337277', agentID: '538559409', licenseKey: 'NRJS-1b1f41c1d6baafe183c', applicationID: config.newRelic.applicationId },
loader_config: { accountID: '4337277', trustKey: '4337277', agentID: config.newRelic.agentId, licenseKey: 'NRJS-1b1f41c1d6baafe183c', applicationID: config.newRelic.applicationId },
}

const _ = new BrowserAgent(options)
Expand Down

0 comments on commit 731d2e0

Please # to comment.