Tree Shaking imports

is it still necessary to import like:
import { Mesh } from '@babylonjs/core/Meshes/mesh
instead of
import { Mesh } from '@babylonjs/core'
to get proper reduced file size?

Unfortunately I sometimes have to look up github to find the right import path.
And VSCode only auto-suggests @babylonjs/core on import. So its really annoying :confused:

Any recommendations how to deal with it?

I think you can play with the import settings of vscode for it:


This seemed to have helped! I used the import Module Specifier option.

1 Like