Open dipaksarkar opened 7 months ago
Added Following commands
parse
Usage: quasalang parse|p [options]
Parse your source files from (/src/**/*.{js,vue}) and Add them to (/translations.csv) as Default language
Options:
-h, --help display help for command
Given the following label in your source files:
<base-label>{{ $t("// Phone Number") }}</base-label>
or
<base-label>{{ $t("// label::Phone Number") }}</base-label>
The command will convert them to:
<base-label>{{ $t("phoneNumber") }}</base-label>
or
<base-label>{{ $t("label.phoneNumber") }}</base-label>
The corresponding translation key will be added to translations.csv
:
phoneNumber,"Phone Number"
or
label.phoneNumber,"Phone Number"
translate
Usage: quasalang translate|t [options]
Translate your CSV file using Google translate
Options:
-h, --help display help for command
check-trans
Usage: quasalang check-trans|ct [options]
Find missing trans key in (/translations.csv) from (/src/**/*.{js,vue})
Options:
-h, --help display help for command
trans-clean
Usage: quasalang trans-clean|tc [options]
Remove unused trans key from (/translations.csv)
Options:
-h, --help display help for command
Sanitize Language Codes:
Modified the generation of import statements in the main index file to sanitize language codes by removing hyphens and converting them to camelCase.
Search and Add i18n Locale Codes