Skip to content

fix: Refactor analytics scripts: update paths#669

Merged
IEvangelist merged 1 commit intomainfrom
dapine/fix-1ds
Apr 3, 2026
Merged

fix: Refactor analytics scripts: update paths#669
IEvangelist merged 1 commit intomainfrom
dapine/fix-1ds

Conversation

@IEvangelist
Copy link
Copy Markdown
Member

fix: Refactor analytics scripts: update paths and reintroduce functionality - fixes #668

Copilot AI review requested due to automatic review settings April 3, 2026 17:33
@IEvangelist IEvangelist requested a review from BethMassi April 3, 2026 17:35
@IEvangelist IEvangelist enabled auto-merge (squash) April 3, 2026 17:35
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the 1DS/track “Unexpected token '<'” runtime errors by moving analytics scripts from Astro endpoint routes to static files under public/ and updating the <script src> paths accordingly.

Changes:

  • Removed /1ds and /track Astro endpoint scripts.
  • Added static analytics scripts at /scripts/analytics/1ds.js and /scripts/analytics/track.js.
  • Updated global head script includes to reference the new static paths.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/frontend/src/pages/track.js Removed endpoint-based tracking script.
src/frontend/src/pages/1ds.js Removed endpoint-based 1DS initialization script.
src/frontend/public/scripts/analytics/track.js Added static click tracking binder script.
src/frontend/public/scripts/analytics/1ds.js Added static 1DS initialization script.
src/frontend/config/head.attrs.ts Updated script src paths to the new static locations.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@IEvangelist IEvangelist merged commit 8606606 into main Apr 3, 2026
9 checks passed
@IEvangelist IEvangelist deleted the dapine/fix-1ds branch April 3, 2026 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1DS issue

3 participants