endojs / endo

Endo is a distributed secure JavaScript sandbox, based on SES
Apache License 2.0
829 stars 72 forks source link

fix(bundle-source): Export types properly #2069

Closed kriskowal closed 8 months ago

kriskowal commented 8 months ago

Description

Using dynamic import in bundleSource made it possible to use bundleSource for one format and not entrain all the tooling for other formats, like Rollup for getExport and Babel for endoZipBase64. But, it broke the flow of type information. This change proposed by @michaelfig rectifies the internal and external types.

Security Considerations

None.

Scaling Considerations

None.

Documentation Considerations

None.

Testing Considerations

This PR does not adequately test the exported type signature. It would pair well with a change that relies on the exported types.

Compatibility Considerations

None.

Upgrade Considerations

None.

kriskowal commented 8 months ago

I’ve tacked on a commit for @dckc to relax the bundle cache option to be actually optional.