This is what I have in <head>:
<script src="https://cdn.jsdelivr.net/npm/codemirror-spell-checker@1.1.2/src/js/spell-checker.min.js" type="text/javascript"></script>
<script src="https://codemirror.net/addon/mode/overlay.js" type="text/javascript"></script>
This fails with error ReferenceError: require is not defined due to an attempt to require typo-js. What I understand is that require will work within Node.js runtime but not in browser. What's the solution?