You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems there is a mismatch between SWC and Babel's plugins behaviours, i quote the posts from Discord discussion
Has anyone encountered a discrepancy with the Lingui number placeholders (e.g., {0}, {1}, {2})
For example I am seeing this locally {2, plural, one {Do X for {0}} other {Do Y for {1}}}
But I see that it is looking for this on my deployed environment, notice the mismatch {0, plural, one {Do X for {1}} other {Do Y for {2}}}
The code snippet
<Pluralone={`Add # item ${amount} to ${name||''}`}other={`Add # items ${amount} to ${name||''}`}value={items?.length||0}/>
Was fixed by changing the snippet to
<Plural
one={`Add # item ${amount} to ${name}`}
other={`Add # items ${amount} to ${name}`}
value={itemsCount}
/>
We use swc for local, I need to check if we switched from babel to swc on prod
Ya I believe prod is babel, so this is likely the culprit, its the only thing different
Need to confirm and prepare a fix.
The text was updated successfully, but these errors were encountered:
It seems there is a mismatch between SWC and Babel's plugins behaviours, i quote the posts from Discord discussion
The code snippet
Was fixed by changing the snippet to
Need to confirm and prepare a fix.
The text was updated successfully, but these errors were encountered: