Skip to content

Conversation

@VeraZab
Copy link
Contributor

@VeraZab VeraZab commented Dec 14, 2017

@bpostlethwaite @alexcjohnson for your review

alexcjohnson
alexcjohnson previously approved these changes Dec 14, 2017
Copy link
Collaborator

@alexcjohnson alexcjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great! no comments from me 💃

package.json Outdated
},
"scripts": {
"combine-translation-strings": "babel-node utils/combineTranslationKeys.js",
"find-strings": "babel-node utils/findLocaleStrings.js",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually find-strings could be changed to npm run make:translations

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or better
npm run make:locale or npm run make:localization

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we're not making translations or localizations, we're making the list of strings from which someone would make the required translations

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or whatever. make:something ;)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make:translation-strings

package.json Outdated
"url": "https://github.com/plotly/react-plotly.js-editor/issues"
},
"scripts": {
"combine-translation-strings": "babel-node utils/combineTranslationKeys.js",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

npm run make:combined-locales ?

Just so it fits in with all the other make stuff?

@bpostlethwaite
Copy link
Member

Since this 'makes' another build artifact required to run in prepublish you could give it a make:? name.

💃 other than that!

@VeraZab
Copy link
Contributor Author

VeraZab commented Dec 14, 2017

haha this approval button's pretty strict, another 👀 @bpostlethwaite ?

const pathToCombinedTranslationKeys = path.join(
__dirname,
'combinedTranslationKeys.txt'
'combinedLocales.txt'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry to nitpick but as @alexcjohnson suggested perhaps we should continue calling these translation-references or translation-strings or something. Locales are the full objects with all the fancy dateFormats and such right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plotly.js calls it's file translation-keys, I could call it translation-keys for the editor too, and combined-translation-keys for the combined file, works?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plotly.js has a rule of all-lowercase filenames, which seems to have fallen out of fashion in more recent js projects, but I won't vote against consistency across repos, I like your proposed names @VeraZab.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sg!

@VeraZab
Copy link
Contributor Author

VeraZab commented Dec 14, 2017

ok, how about those filenames? and also changed some scripts around

@VeraZab VeraZab merged commit 23f760b into master Dec 14, 2017
@VeraZab VeraZab deleted the combine-string-files branch December 14, 2017 21:38
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.

4 participants