Skip to content
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

.ts file feature for translate #253

Open
johnfelipe opened this issue Jun 28, 2023 · 5 comments
Open

.ts file feature for translate #253

johnfelipe opened this issue Jun 28, 2023 · 5 comments

Comments

@johnfelipe
Copy link
Contributor

Will be great if you add .TS files for translate...

@fkirc
Copy link
Owner

fkirc commented Jun 30, 2023

Hi, would it be possible for you to provide a small sample file? Just to be sure what kind of .ts file needs to be translated.

@johnfelipe
Copy link
Contributor Author

Hi dear
https://github.com/Yidadaa/ChatGPT-Next-Web/blob/main/app/locales/en.ts

That one
Is possible add TS file feature
That will be great

@johnfelipe
Copy link
Contributor Author

@fkirc can u help me for translate that kind of .ts file?

@fkirc
Copy link
Owner

fkirc commented Jul 7, 2023

I would be happy to add support for this kind of .ts file, but I am not yet sure how to parse those files.

Since attranslate runs within NodeJS, it cannot directly import TypeScript-files at runtime.
So I guess that some kind of parsing-package would be needed to make this work? https://stackoverflow.com/questions/61148385/read-and-operate-on-a-ts-file-using-node-js

@johnfelipe
Copy link
Contributor Author

johnfelipe commented Jul 7, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants