This is a telegram bot made on Node.js for helping with translations.
I have trying to learn English on my own. But I need to translate a lot of new words and with this bot, it's extremely easy :)
Since wordreference's api is no longer available, I'm doing web scraping using request + cheerio.
- RegExp improved for groups.
- Words are now stored in a MongoDB.
- New web-endpoint with ejs (you can even query the database from there!).
- Now using socket.io for knowing in real time the number of stored translations.
- Highcarts for database usage!
- Logging with winston.
- Moved to es6 syntax.
Long usage mode:
/eng list,of,words: Translate TO English, the words separated by commas
/spa list,of,words: Translates TO Spanish, the words separated by commas
/help: Display help message
Short usage mode:
/spa: Activate mode eng -> spa
/eng: Activa mode spa-> eng
word,to,search for: translate words using the active mode
eng -> spa is active by default
- MONGODB_USER
- MONGODB_PASSWORD
- MONGODB_URL
- MONGODB_DATABASE
- HOST
- PORT
- TOKEN
For more info of everything that has struggled me: