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

Feature: Change WordPress translation domain #53

Open
JasonTheAdams opened this issue Jan 4, 2023 · 1 comment
Open

Feature: Change WordPress translation domain #53

JasonTheAdams opened this issue Jan 4, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@JasonTheAdams
Copy link

I'm getting ready to use this on the new Validation library, and realized we have a need that I think Strauss would be a great fit for.

In the library we're using the WordPress __() translation function. The trick with that function is that the domain can't be a variable, it has to be a plain string for generating the POT file. That would mean the domain would need to be changed from some placeholder to whatever it ought to be during the build process.

The crew at Modern Tribe recently threw a script together that accomplishes this task. But it feels like something that would be a great fit for Strauss to handle.

Thanks!

@JasonTheAdams
Copy link
Author

In the meantime, I ended up including a script with Validation that is run before Strauss which swaps out the domain. Still, this would have to be done with every package, so having this as part of Strauss would be awesome.

@BrianHenryIE BrianHenryIE added the enhancement New feature or request label Nov 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants