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

Automatically add translatable Strings to the .pot file #11

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Automatically add translatable Strings to the .pot file #11

wants to merge 3 commits into from

Conversation

daPhipz
Copy link
Contributor

@daPhipz daPhipz commented Nov 26, 2020

This PR fixes #10.
By importing gettext in fuzzyTime.js, we can use the _ alias to mark translatable Strings.
This enables us to use xgettext in a Script to check if new Strings need to be translated. I will incorporate this in #9 once this PR gets merged!
Run the script with npm run update-po.
It does definitely work, but when I do the npm run test, I get the following error:

$ npm run test
  ReferenceError: imports is not defined

It points specifically to the 2nd line in fuzzyTime.js - the import statement for gettext. As I said - the code runs perfectly, but this error makes it temporarily untestable. Do you know what's the issue here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Automate .pot generation
1 participant