PeculiarVentures / PKI.js

PKI.js is a pure JavaScript library implementing the formats that are used in PKI applications (signing, encryption, certificate requests, OCSP and TSP requests/responses). It is built on WebCrypto (Web Cryptography API) and requires no plug-ins.
http://pkijs.org
Other
1.25k stars 204 forks source link

Upgrade rollup #276

Closed hoihochan closed 3 years ago

YuryStrozhevsky commented 4 years ago

I will check it on my Monday

YuryStrozhevsky commented 4 years ago

@hoihochan So, thanks for the work, but it was useles. The problem is that when you build PKI.js examples you build THREE different sources:

  1. Example source;
  2. Source code for test in Node.js;
  3. Source code for test in browser;

Your changes would work fine in first two items, but not in third. You could check code in <pkijs_dir>\test\browser. The problem is in export word you were using in code. It could not be using in browser part of code. And that is why I put this "hack for Rollup" function in my initial code. Since Rollup had implemented a functionality which anyway removed these functions as "unused" I decided to stay with old Rollup, at least until I would find a time to investiagate the problem more in details. Probably it would require to change Rollup itself. But anyway I could not accept your solution.

hoihochan commented 4 years ago

Thanks! I missed the test code in test/browser...will see if there are ways to fix and make sure it works on the other two as well.