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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't extract translations from siblings folders #990

Open
pybuche opened this issue Mar 14, 2024 · 0 comments
Open

Can't extract translations from siblings folders #990

pybuche opened this issue Mar 14, 2024 · 0 comments

Comments

@pybuche
Copy link

pybuche commented Mar 14, 2024

馃悰 Bug Report

I'm currently working on a yarn workspace monorepo and I need to extract translations from two different workspace.
I decided to create a new workspace called i18n so I setup the i18n object there, store the translations and define extraction scripts there.
However it seems that the input configuration field doesn't look into siblings folders. For instance, with such a tree structure:

i18n/
鈹溾攢 i18n.js
鈹溾攢 i18next-parser-config.js
鈹溾攢 package.json
app1/
鈹溾攢 file.js
鈹溾攢 package.json
app2/
鈹溾攢 file.js
鈹溾攢 package.json

And an i18next-parser-config.js being:

export default {
  defaultNamespace: "common",
  input: ["../**/*.js"],
  output: "locales/$LOCALE/$NAMESPACE.json"
}

It parsers files from i18n/, but not from app1/ or app2/

To Reproduce

I managed to create a minimal repository

Expected behavior

I'd expect the parser to browser folders where I'm asking it to do. Is there a way to do it with the current configuration? Am I missing something? Thanks!

Your Environment

  • runtime version: node 18, chrome latest
  • i18next version: 23
  • os: Mac
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

1 participant