While the .wasm and .hpb files are already compact by design, the .js files are not minified. I highly recommend to use one of the es6-savy JavaScript minifier tools.
If you installed Hyphenopoly with npm run npm run minify to create a directory called min that contains a full set of minified files (and the test suite) minified with terser.
All files have good compression rates when using gzip, deflate and the like. You may need to configure your server to be able to compress .hpb-files though!
Hyphenopoly_Loader.js and Hyphenopoly.js use some basic es6-syntax (let, const, etc. not the fancy stuff). If for some reason you need es5-syntax use babel to transpile the scripts.
Hyphenopoly_Loader.js and Hyphenopoly.js is designed for use in browsers. For usage in node.js see: node module
Let me now, if you have a use case for hyphenation in node.js
Source code).Unpack the package and copy the following files and folders to your server:
Hyphenopoly_Loader.jsHyphenopoly.jshyphenEngine.asm.jshyphenEnginge.wasmpatterns/(Of course you can delete the patterns for the language you won't need.)
Then follow the instructions on https://github.com/mnater/Hyphenopoly#usage-browser
npm i hyphenopoly in your project folder