eloqnt/cli
eloqnt extract
Write the messages that your source code uses to your messages files.
eloqnt extract
messages/
en.json Updated
de.json Updated
✔ Extracted 12 messages
For apps that use useExtracted from next-intl, eloqnt extract reads the messages from the files in srcPath and writes them to the source locale’s messages file.
If a new message is discovered, then target locales will register it as an empty string. If a message is no longer used in code, it will be removed from all messages files.
If a source file can’t be parsed, no messages files are written.
Flags
| --config | string | Path to the eloqnt config file (defaults to .eloqnt/config.{ts,mts,js,mjs}) |
| --json | boolean | Output the result as JSON |