Files
overleaf-cep/services/web/test/frontend/features/chat/components/stubs.ts
Mathias Jakobsen 05bf74cf94 Merge pull request #27790 from overleaf/mj-chat-typescript
[web] Convert remaining chat frontend and tests to typescript

GitOrigin-RevId: 6b2b485433e0a4530f00496e7ecdd49d9eb450af
2025-08-14 08:05:23 +00:00

16 lines
333 B
TypeScript

import sinon from 'sinon'
export function stubMathJax() {
window.MathJax = {
Hub: {
Queue: sinon.stub(),
config: { tex2jax: { inlineMath: [['$', '$']] } },
},
}
}
export function tearDownMathJaxStubs() {
// @ts-expect-error - this is a stub that we're setting ourselves per test
delete window.MathJax
}