Skip to content

Release v0.32.0

Choose a tag to compare

@github-actions github-actions released this 29 Jul 22:18
91c28ef

Nothing breaks in silence. 0.30.0 gave the build gate teeth and 0.31.0 made the commands agree with each other, and this version closes the same story from the other end: every remaining path where Verbaly did the safe thing without telling you now says so, at the moment you can act on it. A plural block that renders an empty string, a currency placeholder with no currency, a message that was written with a plural block in a place that cannot have one, and t imported from a package that does not export it: four ways to ship the wrong text with every command green. Plus the one thing everybody saw and nobody could miss: every single CLI error printed its prefix twice. No breaking changes, no new configuration, no new runtime API.

Highlights

  • A plural block with no catch-all case now warns in the browser, not just in the build. 0.30.0 made the gate refuse it, but a catalog that arrives from a lazy loader, from addMessages or from a CMS never passes through the gate, so the empty string could still reach a real page. Now it names the message and tells you to add an other case.
  • A placeholder missing its argument stops rendering as a bare number. {price:currency} with no currency code, {n:unit} with no unit, {n:relative} with no time unit: each one printed the plain value and said nothing. Each one now says what it needs and shows the shape of the fix.
  • Writing a plural block inside a t template no longer ships as literal braces. In a t template the values come from ${…}, so a plural or format block written there becomes text your users see with the braces still in it. verbaly extract and verbaly doctor now point at the file and the exact text.
  • import { t } from 'verbaly' finally gets an answer that mentions Verbaly. t comes from your instance or from the generated module, never from the package, and until now only the bundler complained, in a message that gave no hint about where t should come from. verbaly doctor names the file and the fix.
  • Every CLI error prints its prefix once. Every failure of the binary read [verbaly] [verbaly] ….

For the full details of this release, see the repository changelog.