actually-colab / desktop

Main web application for @actually-colab, a real time collaborative Jupyter Kernel based editor built by @jtaylorchang and @baileytincher at the University of @Illinois at Urbana-Champaign
https://app.actuallycolab.org
GNU General Public License v2.0
12 stars 1 forks source link

Find ways to decrease bundle size #362

Open jtaylorchang opened 3 years ago

jtaylorchang commented 3 years ago

image

baileytincher commented 3 years ago

Are you tagging me because of the client? It's only 58kb

baileytincher commented 3 years ago

oh, why is it ~3x in your bundle but different on npm? https://www.npmjs.com/package/@actually-colab/editor-client

baileytincher commented 3 years ago

oh, because you're still using the local install.

baileytincher commented 3 years ago

On thing im noticing is that highlight.js is including every single possible language rather than just Python. That looks like a big spot to get savings.

jtaylorchang commented 3 years ago

Note: the biggest gains would come from dropping some of the Highlight/Prism syntax highlighting dependencies. The issue is they're being imported at a low level in the nteract packages. To remove them it would require including modified versions of the following packages and don't import the full syntax highlighter (or at a minimum use the async imports):

These could be rewritten into a src/nteract folder with the excess code gutted and modified for our needs, but it would mean taking ownership of a decent amount of code that can be complicated.