Closed Znegl closed 6 years ago
Hey there! Thanks for reporting this. Yes, at the moment only JS files are supposed to be extracted, so we have to ideally add some configuration setting with a meaningful default. A quick way would be to setup the glob path with ${dir}/**/*.{ts, js}
. There's also a PR from my colleague waiting for review and merge, so we could also include this one in the next version - PRs are welcome, thank you :)
I added this minimal solution to #35. I guess in the future it would be nice to make this whole lookup process more customizable, e.g. by making this part: /**/*.{js,ts}
customizable.
Sounds great! Then I wont do anything for now.
When extracting translations from an Ember project using TypeScript, all translations in
*.ts
files are ignored.I fixed the bug localy by changing
directories.map(dir => `${dir}/**/*.js`)
todirectories.map(dir => `${dir}/**/*.ts`)
inside of_extractFromJS
(which in turn breaks JS support).I would like to create a pull request with a better fix, but before I do that, it would be nice to know if you prefer a new function called
_extractFromTS
or if I should just expand on the JS function to include*.ts
files as well.