Skip to content

feat: Deacon - #967

Open
AndrewCathcart wants to merge 2 commits into
nuxt:mainfrom
AndrewCathcart:add-deacon
Open

AndrewCathcart wants to merge 2 commits into
nuxt:mainfrom
AndrewCathcart:add-deacon

Conversation

@AndrewCathcart

Copy link
Copy Markdown

🔗 Linked issue

None.

📚 Description

I'm one of the founders of Deacon, an AI support agent for websites and apps. This adds it to the registry as useScriptDeacon(), in the support category, following the DeskCrew entry.

Options are key, context (rendered as data-context) and pageViews (false renders data-no-page-views). use() returns window.Deacon, which the loader sets as it runs, and DeaconApi types its methods.

Two things that differ from most entries:

  • crossorigin is off. Our loader.js is served without an Access-Control-Allow-Origin header, so with unhead's default crossorigin="anonymous" Chrome blocks it. I checked both ways in headless Chrome and added Deacon to the CORS guide's list.
  • No bundling or proxy. The loader uses the origin of its own src for the chat frame and API, so a copy served from /_scripts/assets would point everything at the consuming site.

Tests are in test/unit/deacon.test.ts, proxy-configs.test.ts and types.test-d.ts. pnpm lint reports nothing new, pnpm typecheck passes, and the unit and type tests pass. The playground page uses a placeholder key, so the widget loads but can't chat. Happy to add a facade component like Crisp's if you'd like one.

@vercel

vercel Bot commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

@AndrewCathcart is attempting to deploy a commit to the Nuxt Team on Vercel.

A member of the Team first needs to authorize it.

@harlan-zw

Copy link
Copy Markdown
Collaborator

🤖 REVIEW PAUSED

Harlan Agent Kit posted this automated status. AI open source policy.

This pull request is from an outside contributor.

Add the harlan-agent-review label to approve automated review and verified repairs.
Approval covers head commit d2b3f463de45.

@pkg-pr-new

pkg-pr-new Bot commented Oct 22, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@nuxt/scripts-devtools@967
npm i https://pkg.pr.new/@nuxt/scripts@967

commit: d2b3f46

@github-actions

Copy link
Copy Markdown

📦 Package Size

⚠️ 6 size metrics grew

📚 22 runtime dependencies (no change)

Package output Gzipped Δ
@nuxt/scripts · dist/runtime 104 kB → 105 kB 🔴 +857 B (+0.8%)
@nuxt/scripts · export ./registry 30 kB → 31 kB 🔴 +539 B (+1.8%)
@nuxt/scripts · export ./stats 13 kB → 13 kB 🔴 +23 B (+0.2%)
@nuxt/scripts · export ./types-source 49 kB → 50 kB 🔴 +964 B (+2.0%)
@nuxt/scripts · published payload 223 kB → 225 kB 🔴 +2.4 kB (+1.1%)
@nuxt/scripts · registry runtime 46 kB → 46 kB 🔴 +857 B (+1.9%)
All tracked output (25)
Package output Gzipped Raw
@nuxt/scripts-cli · runtime dependencies 72 kB 355 kB ✅
@nuxt/scripts-cli · dependency magicast 72 kB 355 kB ✅
@nuxt/scripts-cli · export . 3.4 kB 12 kB ✅
@nuxt/scripts-cli · published payload 3.4 kB 12 kB ✅
@nuxt/scripts · runtime dependencies 543 kB 2.40 MB ✅
@nuxt/scripts · dependency @oxc-project/types 0 B 0 B ✅
@nuxt/scripts · dependency @vueuse/core 178 kB 720 kB ✅
@nuxt/scripts · dependency @vueuse/shared 39 kB 152 kB ✅
@nuxt/scripts · dependency lru-cache 141 kB 623 kB ✅
@nuxt/scripts · dependency semver 25 kB 72 kB ✅
@nuxt/scripts · dependency sirv 8.8 kB 21 kB ✅
@nuxt/scripts · dependency unstorage 70 kB 225 kB ✅
@nuxt/scripts · dependency valibot 82 kB 590 kB ✅
@nuxt/scripts · dist/runtime 105 kB 308 kB 🔴
@nuxt/scripts · export . 26 kB 106 kB ✅
@nuxt/scripts · export ./registry 31 kB 96 kB 🔴
@nuxt/scripts · export ./stats 13 kB 93 kB 🔴
@nuxt/scripts · export ./types-source 50 kB 250 kB 🔴
@nuxt/scripts · published payload 225 kB 854 kB 🔴
@nuxt/scripts · app runtime 176 B 658 B ✅
@nuxt/scripts · components runtime 2.5 kB 6.4 kB ✅
@nuxt/scripts · composables runtime 7.8 kB 26 kB ✅
@nuxt/scripts · registry runtime 46 kB 138 kB 🔴
@nuxt/scripts · server runtime 30 kB 89 kB ✅
@nuxt/scripts · utils runtime 2.9 kB 8.1 kB ✅
Runtime dependencies (22)
Package Dependency Requested Resolved Cost
@nuxt/scripts-cli magicast ^0.5.5 0.5.5 📦 72 kB gzip
@nuxt/scripts-cli pathe ^2.0.3 2.0.3 ♻️ free via Nuxt 4.6.0
@nuxt/scripts @nuxt/kit ^4.6.0 4.6.0 ♻️ free via Nuxt 4.6.0
@nuxt/scripts @oxc-project/types ^0.153.0 0.153.0 📦 0 B gzip
@nuxt/scripts @vueuse/core ^15.0.0 15.0.0 📦 178 kB gzip
@nuxt/scripts @vueuse/shared ^15.0.0 15.0.0 📦 39 kB gzip
@nuxt/scripts consola ^3.4.2 3.4.2 ♻️ free via Nuxt 4.6.0
@nuxt/scripts defu ^6.1.7 6.1.7 ♻️ free via Nuxt 4.6.0
@nuxt/scripts lru-cache ^11.5.3 11.5.3 📦 141 kB gzip
@nuxt/scripts magic-string ^1.4.3 1.4.3 ♻️ free via Nuxt 4.6.0
@nuxt/scripts ofetch ^1.5.1 1.5.1 ♻️ free via Nuxt 4.6.0
@nuxt/scripts ohash ^2.0.12 2.0.12 ♻️ free via Nuxt 4.6.0
@nuxt/scripts oxc-walker ^1.1.1 1.1.1 ♻️ free via Nuxt 4.6.0
@nuxt/scripts pathe ^2.0.3 2.0.3 ♻️ free via Nuxt 4.6.0
@nuxt/scripts semver ^7.8.5 7.8.5 📦 25 kB gzip
@nuxt/scripts sirv ^3.0.2 3.0.2 📦 8.8 kB gzip
@nuxt/scripts std-env ^4.3.0 4.3.0 ♻️ free via Nuxt 4.6.0
@nuxt/scripts ufo ^1.6.4 1.6.4 ♻️ free via Nuxt 4.6.0
@nuxt/scripts ultrahtml ^1.7.0 1.7.0 ♻️ free via Nuxt 4.6.0
@nuxt/scripts unplugin ^3.4.0 3.4.0 ♻️ free via Nuxt 4.6.0
@nuxt/scripts unstorage ^1.17.5 1.17.5 📦 70 kB gzip
@nuxt/scripts valibot ^1.5.0 1.5.0 📦 82 kB gzip

Baseline: main_@_321e7574___2026-10-13 · gzip is the comparison metric · changes below 16 B gzip are ignored

@coderabbitai

coderabbitai Bot commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: feca4078-5a23-4bc1-8a75-d64b28702118
📥 Commits

Reviewing files that changed from the base of the PR and between 321e757 and d2b3f46.

📒 Files selected for processing: 15
  • docs/content/docs/1.guides/6.cors.md
  • docs/content/scripts/deacon.md
  • packages/script/src/registry-logos.ts
  • packages/script/src/registry-types.json
  • packages/script/src/registry.ts
  • packages/script/src/runtime/registry/deacon.ts
  • packages/script/src/runtime/registry/schemas.ts
  • packages/script/src/runtime/types.ts
  • packages/script/src/script-meta.ts
  • playground/nuxt.config.ts
  • playground/pages/index.vue
  • playground/pages/third-parties/deacon.vue
  • test/types/types.test-d.ts
  • test/unit/deacon.test.ts
  • test/unit/proxy-configs.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

📝 Walkthrough

The change adds Deacon as a registry script with configuration and API types, a runtime schema, and a loader composable. It adds script metadata and registry tests, documents setup and configuration, and provides a playground page with chat and visitor-identification controls.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~25 minutes

Merge Risk: ⚪ Minimal · up to d2b3f

No confirmed issue in the Deacon integration currently prevents merging after normal checks.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 10 files. (5 skipped: … Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title clearly identifies the main change: adding Deacon support.
Description check Passed The description directly explains the Deacon registry integration, options, behavior, implementation differences, tests, and validation results.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 10 files. (5 skipped: 5 unsupported.)

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

✨ Finishing Touches: 💡 1
🛠️ Fix failing CI checks: 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@AndrewCathcart

AndrewCathcart commented Oct 23, 2026 •

Copy link
Copy Markdown
Author

Hi @harlan-zw - I've pre-emptively opened this after posting in here #177 (comment) - let me know if you'd rather discuss first! Appreciate it.

This branch has not been deployed

No deployments
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.

2 participants