stackblitz / webcontainer-core

Dev environments. In your web app.
https://webcontainers.io
MIT License
3.92k stars 169 forks source link

Webcontainer Snapshot #1033

Open alew3 opened 1 year ago

alew3 commented 1 year ago

A Webcontainer takes a long time to startup as it needs to configure the environment, download and install npm files.

Ideally we should be able to create a snapshot of the webcontainer similiar to a Dockerfile. So startup time is instant.

SamVerschueren commented 1 year ago

Hi @alew3! Thanks for reaching out.

Regarding installing node modules, make sure to generate and save the lock file (package-lock.json, yarn.lock, or pnpm-lock.yaml). That should drastically improve installation times.

Anyways, I created a ticket for this to track internally.