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

Avoid inserting files into Pluto's frontend-dist folder #39

Closed
fonsp opened this issue Feb 7, 2024 · 2 comments · Fixed by #44
Closed

Avoid inserting files into Pluto's frontend-dist folder #39

fonsp opened this issue Feb 7, 2024 · 2 comments · Fixed by #44

Comments

@fonsp
Copy link
Member

fonsp commented Feb 7, 2024

Let's figure out together how we can avoid inserting files into the frontend-dist folder of Pluto. This hack seems to work quite well, but my worries are:

  • This creates inflexibility in future development. If you stick to the known and documented API, then we are flexible to change things internally without breaking packages that use API.
  • Or for example, if VS Code were to support some of our special display API, then we want PlutoPlotly.jl to work. Also within the Pluto ecosystem, we display notebooks in lots of environments, like locally, from a remote server, from a CDN, from the future pluto.land, with inlined assets, and those things become harder to develop.
  • PlutoPlotly.jl should give an example to other Pluto-integrating packages on how to do these things :)
  • Dogfooding: if there are missing Pluto features, we should add them instead of working around it.
@disberd
Copy link
Member

disberd commented Feb 8, 2024

Yeah I'd be more than happy to have an official way to do this with Pluto API.

I didn't even publicize this as it was more experimenting on how to get offline plotly easily (though there should still be a fallback to cdn if this fails so it won't break plots in the general sense) and I always wanted to find a more proper approach so let's discuss this :D.

As I mentioned some time ago I don't think the approach in your example notebook about importing local js is feasible as it will send the full library as String at least during manual rerun, and this being a few Mb it gives quite a bit of lag (almost 1 second on my pc)

@fonsp
Copy link
Member Author

fonsp commented Feb 13, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants