PrivateBin/js
rugk 3942e546b6 refactor: simplify cleanup() and document why module reload is required
Remove defensive checks that are guaranteed by jsdom-global (window and
document are always set), the jQuery alias for PrivateBin (unused after
jQuery removal), and the conditional re-export block.

The module reload (delete require.cache + re-require) is intentional and
necessary: modules like CopyToClipboard hold DOM element references in
closure variables and schedule setTimeout callbacks. Without a reload,
those callbacks fire against elements from a now-dead jsdom window after
cleanup(), causing cross-test interference. Document this clearly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-15 18:26:26 +02:00
..
test test: fix ServerInteraction crypto setup and PasteViewer test stability 2026-06-15 17:32:52 +02:00
.istanbul.yml
.nycrc.yml
base-x-5.0.1.js
bootstrap-3.4.1.js
bootstrap-5.3.8.js
comment.jsonld
commentmeta.jsonld
common.js refactor: simplify cleanup() and document why module reload is required 2026-06-15 18:26:26 +02:00
dark-mode-switch.js
eslint.config.js exclude generated ES6 module from ESlint 2026-04-03 18:42:32 +02:00
jquery-3.7.1.js
jsconfig.json
kjua-0.10.0.js
legacy.js
package-lock.json Merge remote-tracking branch 'origin/master' into js/removeJQuery 2026-05-22 19:32:31 +00:00
package.json Merge remote-tracking branch 'origin/master' into js/removeJQuery 2026-05-22 19:32:31 +00:00
paste.jsonld
pastemeta.jsonld
prettify.js
privatebin.js fix: clear prettyprinted class when re-rendering as plaintext/markdown 2026-06-15 17:32:19 +02:00
purify-3.4.1.js update DOMpurify library from 3.4.0 to 3.4.1 2026-04-23 07:15:03 +02:00
showdown-2.1.0.js
types.jsonld
zlib-1.3.2.js avoid mjs for now, inject map, Buffer is node-only 2026-04-04 10:22:10 +02:00
zlib-1.3.2.wasm updating zlib to 1.3.2 2026-04-03 18:15:54 +02:00
zlib.js avoid mjs for now, inject map, Buffer is node-only 2026-04-04 10:22:10 +02:00