Skip to content

docs: explain LISTEN channel identifier quoting - #1101

Open
psh4607 wants to merge 3 commits into
electric-sql:mainfrom
psh4607:docs/GH-747/listen-channel-quoting
Open

docs: explain LISTEN channel identifier quoting#1101
psh4607 wants to merge 3 commits into
electric-sql:mainfrom
psh4607:docs/GH-747/listen-channel-quoting

Conversation

@psh4607

@psh4607 psh4607 commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

작업 배경

PGlite already supports PostgreSQL identifier quoting for LISTEN channel names, but the API documentation did not make it clear that names containing hyphens or other special characters must be passed as quoted identifiers.

티켓 및 링크

작업 내용

  • Replace the basic listen() example with a copy-pastable quoted channel name containing a hyphen and a matching NOTIFY statement.
  • Explain PostgreSQL's lowercase folding for unquoted identifiers and the case-preserving, special-character behavior of double-quoted identifiers.
  • Clarify that quoted identifiers can subscribe and receive notifications, but per-channel cleanup is not reliable in either PGlite or PGliteWorker; use an unquoted identifier when cleanup is required.
  • Keep the change documentation-only; no API behavior, source, tests, or changeset are changed.

테스트

  • pnpm --dir docs stylecheck
  • pnpm --dir docs typecheck
  • VitePress Markdown renderer structural check for the quoted LISTEN/NOTIFY example, the absence of quoted unlisten() guidance, and the cleanup limitation
  • git diff --check
  • pnpm --dir docs build — blocked before page rendering because this fresh worktree does not contain the generated packages/pglite/dist/index.js workspace artifact; a direct @electric-sql/pglite import fails at the same missing entry point

@psh4607
psh4607 marked this pull request as ready for review August 26, 2026 03:50
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.

Channel name with hyphen does not work

1 participant