-
Notifications
You must be signed in to change notification settings - Fork 397
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Typescript without React? #1206
Comments
I've gotten it a little bit further. It turns out the config I needed in package.json was However, I've got a different error now when I try to build with webpack 5:
It looks like it's trying to call some node APIs that aren't available. It looks like lingui has Webpack 5 support so I'm not sure why this is broken. I see Babel mentioned a lot in the docs but I'm not using Babel to create my JS; it's just done via |
Finally got it working, following steps in https://github.com/Microsoft/TypeScript-Babel-Starter . I had to abandon Also needed to |
Now I need to apply it to my project with yarn workspaces and Typescript project references. Before I would just compile with I'm wondering if at this point it might be easier to migrate to Lit so I can use their localization library. If anyone is using Lingui successfully with yarn workspaces let me know. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Fixed in #1367 would be released as part of v4 |
There is a React Typescript sample, but it assumes you are using React. There is a Vanilla JS sample, but without TypeScript integration.
I'm a bit confused: do I need Babel? The React example doesn't seem to use it.
I have a minimal project set up here to attempt to get this running without React: https://github.com/RandomEngy/lingui-ts
However when I run
lingui extract
it errors out:The text was updated successfully, but these errors were encountered: