To make your life easier in JS you may want to export to JSON as you can consume JSON very easily in JS as it is literally JavaScript Object Notation. You could then just load in the JSON file and use it right away in your program.
The question then becomes,  how big are those files? You can certainly download large files to the browser, but if on mobile phone on bad wireless connection it could take long time. If over say 10Mb in size then maybe you want to store serverside and just use websockets to talk to a Node.js server to which you can send a sentence and get back an encoding and have the dictionary stored in memory so super fast response time. Something like that.
Many ways to do it depending on your needs - if you dont need a fast loading time then sending the JSON to client is completely fine too.