Reputation: 1635
Is there a gem to detect if a language is non-english?
I need to pass in a string and if it is not english, return an appropriate value.
Thanks
Upvotes: 3
Views: 673
Reputation: 5400
I'm using CLD which I really like, succinct and easy to use, give it a try.
Upvotes: 2
Reputation: 10393
WhatLanguage gem is your best bet. But it is not perfect, though.
Upvotes: 2
Reputation: 1484
There is a gem for the Google translate API, that handles, among other things, language detection. It's a paid service though: https://developers.google.com/translate/v2/libraries
Upvotes: 2