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
{{ message }}
Repository navigation
Compile to FormatJS compiled format with formatphp compile CLI command #95
Compile to FormatJS compiled format with formatphp compile CLI command
We already have the compilation capability built-in to FormatPHP, for validation purposes. We should expose this to users through a formatphp compile command that works similarly to the formatjs compile command.
This will enable sharing the same translation files across front-end and back-end code.
Background/problem
FormatJS has a special compilation step that helps improve performance and efficiency internally, since it's a type of AST for translation strings. You can read more about the compile command here:
FormatPHP already implements the same AST compilation process in order to validate messages. We need to expose this as a compile command to output the AST and save to a file. With this functionality, users could merge their translation files to usethe same ones for front-end and back-end.
Activity