v5.23.0: Module '"@tolgee/i18next"' has no exported member 'Tolgee'.ts
Importing Tolgee fails starting from @tolgee/i18next v5.23.0.
This line:
import { Tolgee } from '@tolgee/i18next';
Throws:
Module '"@tolgee/i18next"' has no exported member 'Tolgee'.ts
It works fine with @tolgee/i18next v5.22.0.
Hey, we've changed the build system to vite on the web package in that release. Could you share more about your environment?
@stepan662 sure, I've set up a minimal reproduction: https://github.com/flolu/tolgee-i18next-v5-23-issue (TypeScript built with SWC, uses Node.js ESM)
Hey, I was digging into this, however I was not able to find a satisfying solution. The issue seems to be triggered by "moduleResolution": "node16". In our package "@tolgee/web", we have "type: module", which seems to cause typescript in this mode resolution is failing to import relative paths without file extension. However I didn't find any way how to force tsc to include file extensions in .d.ts files.
The issue is actually fixed if I remove "type: module" from our package, but that causes many other issues for us, so that is not currently possible.
@stepan662 I'm afraid I can't help you here.