Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optional `@finos/perspective-webpack-plugin` #870

Merged
merged 3 commits into from Jan 15, 2020
Merged

Conversation

@texodus
Copy link
Collaborator

texodus commented Jan 13, 2020

Makes @finos/perspective default to export a WASM-inlined build, which inlines the WASM payload as base64 and the WebWorker as an inline string. With this change, by default:

  • All @finos/perspective* modules will build without @finos/perspective-webpack-plugin.
  • All bundlers (including webpack) will work without special configuration.

But:

  • Bundle outputs will be ~500kb larger (due to base64 encoding overhead).
  • Initial load will be slower (though engine runtime once loaded will not be affected).
  • Debuggers which try to load the raw JS file may go haywire.

So by default, perspective will now be easier to install, but output a slightly worse build. By using @finos/perspective-webpack-plugin, the build will still work as currently, outputting the independent perspective.wasm.worker.js and psp.async.wasm, with no performance impact.

This is intended to address many recent support questions about build errors for new users e.g. #860 #857

On the side, this also makes perspective-test output screenshots from different architectures to separate folders, which makes testing across docker/local puppeteer much more convenient.

@texodus texodus force-pushed the optional-webpack-plugin branch from 7034fff to 525b481 Jan 13, 2020
@sc1f
sc1f approved these changes Jan 13, 2020
@texodus texodus force-pushed the optional-webpack-plugin branch from 34e76ad to 72e9b20 Jan 14, 2020
@texodus texodus merged commit 860534f into master Jan 15, 2020
6 checks passed
6 checks passed
Travis CI - Pull Request Build Passed
Details
continuous-integration/appveyor/branch AppVeyor build succeeded
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
verification/cla-signed
Details
@texodus texodus deleted the optional-webpack-plugin branch Jan 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.