Models disappear in production mode after migrating CRA to vite

I’m working on such issue Switch a built system to vite by NiEkOKsU · Pull Request #1696 · yaptide/ui · GitHub, where I’m trying to migrate our applications from CRA to vite. After a building the application and running preview, three js models in editor tab don’t load. When i start app by npm run start, everything works correctly.
Preview:


From npm run start:

Code used for the editor should be in src/ThreeEditor. There are any additional warnings/errors when i’m opening app from preview.