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

docs: add catalogsMergePath in Lingui Configuration #1881

Merged
merged 8 commits into from
Mar 11, 2024

Conversation

aseerkt
Copy link
Contributor

@aseerkt aseerkt commented Mar 8, 2024

Description

Include catalogsMergePath in Lingui Configuration reference section in docs

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Examples update

Fixes #1879

Checklist

  • I have read the CONTRIBUTING and CODE_OF_CONDUCT docs
  • I have added tests that prove my fix is effective or that my feature works
  • I have added the necessary documentation (if appropriate)

Copy link

vercel bot commented Mar 8, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
js-lingui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 11, 2024 2:51pm

@aseerkt aseerkt changed the title docs: add catalogsMergePath in **Lingui Configuration** docs: add catalogsMergePath in *Lingui Configuration* Mar 8, 2024
@aseerkt aseerkt changed the title docs: add catalogsMergePath in *Lingui Configuration* docs: add catalogsMergePath in Lingui Configuration Mar 8, 2024
Copy link

github-actions bot commented Mar 8, 2024

size-limit report 📦

Path Size
./packages/core/dist/index.mjs 2.86 KB (0%)
./packages/detect-locale/dist/index.mjs 723 B (0%)
./packages/react/dist/index.mjs 1.67 KB (0%)
./packages/remote-loader/dist/index.mjs 7.26 KB (0%)

Copy link

codecov bot commented Mar 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.63%. Comparing base (93204b9) to head (008c7b7).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1881      +/-   ##
==========================================
- Coverage   76.66%   76.63%   -0.03%     
==========================================
  Files          81       81              
  Lines        2083     2089       +6     
  Branches      532      534       +2     
==========================================
+ Hits         1597     1601       +4     
  Misses        375      375              
- Partials      111      113       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

website/docs/ref/conf.md Outdated Show resolved Hide resolved
website/docs/ref/conf.md Outdated Show resolved Hide resolved
@timofei-iatsenko
Copy link
Collaborator

timofei-iatsenko commented Mar 11, 2024

BTW it still not clear from the docs what actually it does. Maybe add some examples with files tree before and after?

@aseerkt
Copy link
Contributor Author

aseerkt commented Mar 11, 2024

Thanks for the suggestion 🤗.
I have updated the example. Please have a look.

@andrii-bodnar
Copy link
Contributor

@aseerkt Thanks! I would suggest making the example more compact: use the code diff highlight to show what the file structure is before the merge (-) and after the merge (+) on a single block of code.

@andrii-bodnar
Copy link
Contributor

Also, we can reference our input data by the #separate-catalogs-per-component-placed-inside-component-dir hash, just to not copy-paste the initial config and files structure.

@aseerkt
Copy link
Contributor Author

aseerkt commented Mar 11, 2024

Thanks for the suggestion.
PTAL @andrii-bodnar

@timofei-iatsenko
Copy link
Collaborator

maybe weird question, but, anyone tested this "Separate catalogs per component, placed inside component dir"? i don't remember this working from the code perspective..

@aseerkt
Copy link
Contributor Author

aseerkt commented Mar 11, 2024

@aseerkt
Copy link
Contributor Author

aseerkt commented Mar 11, 2024

We need to fix the catalogs configuration in the docs in couple of places, where include is typed as string[]

{
  "catalogs": [
    {
      "path": "/locale/{locale}/{name}",
-     "include": "components/{name}/"
+     "include": ["components/{name}/"]
    }
  ],
 }

Should I account for these changes in this PR?

@andrii-bodnar
Copy link
Contributor

@aseerkt could you please fix this within the current PR?

Copy link
Contributor

@andrii-bodnar andrii-bodnar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aseerkt thank you!

@andrii-bodnar andrii-bodnar merged commit a7ead64 into lingui:main Mar 11, 2024
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The catalogsMergePath option is missing in the documentation
3 participants