Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation: Add an example on how to prettify the results after translation #5

Open
lyqht opened this issue Jul 26, 2023 · 0 comments
Labels
documentation Improvements or additions to documentation

Comments

@lyqht
Copy link
Owner

lyqht commented Jul 26, 2023

Context

For JSON files, after translating, it generates something like this at the moment,

{"pages":{"login":{"title":"アカウントにサインインする","signin":"ログイン","signup":"登録する","divider":"または","fields":{"email":"電子メール","password":"パスワード"},"errors":{"validEmail":"無効なメールアドレス"},"buttons":{"submit":"ログイン","forgotPassword":"パスワードをお忘れですか?","noAccount":"アカウントをお持ちでないですか?","rememberMe":"リメンバー・ミー"}},"forgotPassword":{"title":"パスワードをお忘れですか?","fields":{"email":"電子メール"},"errors":{"validEmail":"無効なメールアドレス"},"buttons":{"submit":"リセットの指示を送る"}},"register":{"title":"アカウント登録","fields":{"email":"電子メール","password":"パスワード"},"errors":{"validEmail":"無効なメールアドレス"},"buttons":{"submit":"登録","haveAccount":"アカウントをお持ちですか?"}},"updatePassword":{"title":"パスワードの更新","fields":{"password":"新しいパスワード","confirmPassword":"新しいパスワードの確認"},"errors":{"confirmPasswordNotMatch":"パスワードが一致しない"},"buttons":{"submit":"更新"}},"error":{"404":"申し訳ありませんが、あなたが訪問したページは存在しません。","info":"{{resource}} リソースに{{action}} コンポーネントを追加するのを忘れているかもしれません。","resource404":"{{resource}} リソースを作成しましたか?","backHome":"ホームへ戻る"}},"actions":{"list":"リスト","create":"作成","edit":"編集","show":"ショー"},"buttons":{"create":"作成","save":"セーブ","logout":"ログアウト","delete":"削除","edit":"編集","cancel":"キャンセル","confirm":"本当か?","filter":"フィルター","clear":"クリア","refresh":"リフレッシュ","show":"ショー","undo":"元に戻す","import":"輸入","clone":"クローン","notAccessTitle":"アクセス権限がありません"},"warnWhenUnsavedChanges":"本当に帰りたいのか?救われていない変化がある。","notifications":{"success":"成功","error":"エラー (ステータスコード:{{statusCode}})","undoable":"{{seconds}} 、取り消すことができます。","createSuccess":"作成に成功{{resource}}","createError":"{{resource}} を作成する際にエラーが発生しました(ステータスコード:{{statusCode}} )。","deleteSuccess":"削除に成功{{resource}}","deleteError":"{{resource}} 削除時のエラー (ステータスコード:{{statusCode}})","editSuccess":"編集に成功{{resource}}","editError":"{{resource}} 編集時のエラー (ステータスコード:{{statusCode}})","importProgress":"インポートする:{{processed}}/{{total}}"},"loading":"ローディング","tags":{"clone":"クローン"},"dashboard":{"title":"ダッシュボード"},"posts":{"posts":"投稿","fields":{"id":"アイド","title":"タイトル","category":"カテゴリー","status":{"title":"ステータス","published":"出版","draft":"ドラフト","rejected":"不採用"},"content":"内容","createdAt":"作成日時"},"titles":{"create":"ポスト作成","edit":"投稿を編集する","list":"投稿","show":"投稿を表示する"}},"table":{"actions":"行動"}}

Some users might want to read the JSON, however at the same time, if we do perform prettify-ing or eslint formatting, it should be based on the user's project configuration.

Possible solution

You can make a PR to edit the action so that it can run any user-specific commands before triggering the auto-commit-action

@lyqht lyqht added the documentation Improvements or additions to documentation label Jul 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

1 participant