iotaledger / curl.lib.js

IOTA Proof-of-Work algorithm ported to Javascript to work in WebGL2-enabled browsers
GNU General Public License v3.0
37 stars 31 forks source link

dist/curl.min.js is not minified #14

Open normpad opened 7 years ago

normpad commented 7 years ago

After running

npm install npm run compile

The file dist/curl.min.js is not minified. It is 10,000 lines long and does not function when included in a javascript app where an old version of curl.min.js was used.

paulhandy commented 7 years ago

Thanks for notifying me! Optimization regressions...

paulhandy commented 7 years ago

In the meantime, you could require and webpack for your own application, which has worked quite well for my purposes.

pRizz commented 7 years ago

@normpad Here is what I had to do to get it working:

npm install -g webpack
mv webpack.config.js webpack.config.js.bak # ignore config in current directory
webpack src/index.js curl.min.js # creates curl.min.js that attaches to the browser window object

Another snag is that you have to call curl.init() before using it. I think this was a recent addition. Another issue is that I get an error about invalid transaction hash when interacting with the IOTA nodes. Maybe there is a bug here.

mrbianchi commented 6 years ago

@pRizz same problem here

AaronVasquez commented 6 years ago

Any updates on this issue?

desjob commented 5 years ago

i think this can be closed. i ran npm run build on the master branch today, and it produced a minified curl.min.js in the dist folder