It looks like you have used the legacy export and then that should work. Otherwise you can just import Mesh directly and use the method - it is declared static on the Mesh object. Importing directly will help with tree shaking and is probably the recommended way to go.
Sorry I think my question was abit unclear, I was trying to find the MergeMeshes function from @babylonjs/core so that I could import it as a ES6 module but could not find it.
So I ended up using;
import * as BABYLON from “@babylonjs/core/Legacy/legacy”
no, it was my answer that could have used more clarity. you did the import correctly for the legacy import and that looks to me like it should work. The “correct” way in my opinion though is to import directly when using ES6. ie:
import { Mesh } from '@babylonjs/core/Meshes/mesh'
// then call static method directly
const mergedMeshes: Nullable<Mesh> = Mesh.MergeMeshes([sphere, cube, ground]);