X18N4008: Invalid edit input

Invalid edit input. Check the input shape against the docs.

Message

[X18N4008] Invalid edit input <detail>
├▶ fix: Check the input shape against the docs.
╰▶ see: https://x18n.antfu.dev/errors/x18n4008

The CLI prints the code and why the error happened, with details such as a file name or a field. The fix and a link to this page follow. With --json, the same parts are in errors of the envelope.

What to do

The input of an edit has the wrong shape.

  • x18n set needs --value <text> (or --value - to read stdin).
  • x18n apply needs JSON in the shape { "<locale>": { "<key>": "<value>" } }. Values are strings, numbers, booleans or null.
  • x18n extract --apply needs a plan file written by x18n extract --plan.

Exit code

The CLI exits with code 1.

Source