Check out the book Single Page Web Applications (2013), and its author's blog https://michaelmikowski.com/
He has been an advocate of this frameworkless approach for many years, and in his book he shows exactly how it's done (might have aged a bit, pre-ES6, this niche is moving fast, but the gist hasn't changed).
The running example in the book is a chat web app with a frameworkless js front end and a node.js backend, using socket.io and mongo.
For what it's worth, this is one of the recommended books for MIT's web dev course alongside Javascript The Good Parts, Ninja and Patterns (https://stellar.mit.edu/S/course/6/fa18/6.170/courseMaterial...)