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

Update index.js to allow for language additions from outside of the API #18

Merged
merged 8 commits into from
Aug 20, 2019
Merged

Update index.js to allow for language additions from outside of the API #18

merged 8 commits into from
Aug 20, 2019

Conversation

rawr51919
Copy link

@rawr51919 rawr51919 commented Mar 21, 2019

Updates index.js to allow for language additions from outside of the API (carryover from unmaintained upstream PR matheuss#31).

@vitalets
Copy link
Owner

vitalets commented Apr 1, 2019

Good feature! Could you add to readme a usage example?

@rawr51919
Copy link
Author

rawr51919 commented Apr 1, 2019

Good feature! Could you add to readme a usage example?

Sure. I can reference what the original upstream PR had for instructions and mirror those in the readme if you like.
The new feature allows for things like this to be done (code again from matheuss#31):

Gta = require('google-translate-api');
Gta.languages['sr-Latn'] = 'Serbian Latin';
Gta.languages['sr-Cyrl'] = 'Serbian Cyrillic';

EDIT: Done.

@codecov-io
Copy link

Codecov Report

Merging #18 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #18   +/-   ##
=======================================
  Coverage   92.42%   92.42%           
=======================================
  Files           2        2           
  Lines          66       66           
=======================================
  Hits           61       61           
  Misses          5        5
Impacted Files Coverage Δ
index.js 90.19% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 541d4fb...96a0fba. Read the comment docs.

@vitalets
Copy link
Owner

This is cool! 👍
Please

  • rebase to master to resolve conflicts in readme
  • add test for that feature

Updates index.js to allow for language additions from outside of the API
Update the readme as per vitalets' suggestion
@rawr51919
Copy link
Author

The repo's been rebased around the current master. The test for this will be worked on shortly.

@rawr51919
Copy link
Author

I've coded a WIP test for this particular feature. Testing would be very much appreciated.

@vitalets vitalets merged commit b70ec9b into vitalets:master Aug 20, 2019
@vitalets
Copy link
Owner

Thank you! 👍

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.

3 participants