Jump to content

Working on 3d project, only concern being the size, is npm import gonna help?


Recommended Posts

I'm working on a web AR project, where I've got the freedom to choose whichever 3d engine I like, and I like babylonjs.

The only concern right now is the minified gzip bundle of babylonjs is around 454 kb, which is too big. https://bundlephobia.com/result?p=babylonjs@3.3.0-rc.3Not gonna use every single functionality of babylonjs, so my question is: is there a way around it, if I'm only gonna use partial of babylonjs?

if I'm installing the npm package and import only the part I need, like

import { AbstractMesh } from "babylonjs";

import { AdvancedDynamicTexture, Rectangle, Control, TextBlock } from "babylonjs-gui"; 

Will I be able the decrease the size of the bundle?

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...