-
Notifications
You must be signed in to change notification settings - Fork 59
Description
make-json extract JavaScript strings from PO files with .js and .min.js files extensions while generating individual JSON files like it should. But I have JS files with other extensions (for example .tag), which ignored this way.
In /i18n-command/blob/master/src/MakeJsonCommand.php start at 134 line I found code which responsible for it. So there inside iteration it check for each extension and return source if was found. Off course, I can "hardcode" and this will work. Something like:
if ( substr( $file, - 4 ) === '.tag' ) {
return $file;
}
But my request is in core update from your side, because I think a lot of people will use with feature for their own purposes and there can be a great variety of similar extensions. Feature must be multipurpose for any extension and, desirable, provide this opportunity to programmers at their own discretion (like --extensions=tag argument or something similar). I.e additional to .js and .min.js will search for extensions specified in --extensions argument.
Or maybe you have any other suggestions for resolving my request? I am open to discussion and ready to listen to any suggestions.
Thanks!