Share your repls and programming experiences

← Back to all posts
Google translate app
rjlevy (345)

Built with Node, Express, EJS and Bootstrap

Commentshotnewtop
Wilke000 (488)

So fun to play around with lol

LTI2 (65)

viileä! made with translation

rjlevy (345)

Hi @LTI2, nice one! I think that's cool in Finish 🇫🇮

Soccer135246 (2)

WAAAAAAAT? No translating into chinese?

rjlevy (345)

Hi @Soccer135246, thank you for your suggestion. I have just added Chinese to the list of languages. I had to choose either Chinese Simplified or Chinese Traditional. Which one do you think is better? Here is a list of all the languages supported by Google Translate: https://cloud.google.com/translate/docs/languages

potatojs (774)

great job!

i see arabic in there and there isn't a flag,
you can just write AR for arabic it's better then nothing :D

rjlevy (345)

thanks @potatojs! Thanks for the suggestion - I've added Arabic with a flag, it's at the top of the dropdown menu, as shown attached. Can you see it now?

potatojs (774)

no, i don't see any flags, maybe the problem is in my [email protected]

rjlevy (345)

Hi @potatojs, that's strange. I know there have been issues with emojis working on Windows 10 in the past. Which operating system and browser are you using?

potatojs (774)

hi @rjlevy , i am using windows 7 chrome

ZDev1 (533)

why there is no arabic?

rjlevy (345)

Hi @ZDev1, I want to add Arabic but I don't know what flag to use as each flag is specific to only one country

ZDev1 (533)

@rjlevy add UAE or KSA
KSA = saudi arabia
UAE = united arabic states
btw I am arabian and I'd like to see it ;)

rjlevy (345)

Hi @ZDev1, thank's for the suggestion. I have added Arabic, but we can only choose one flag because Google Translate API only has one option for Arabic: ar listed here

I chose the United Arabic Emirates flag shown here but we can change it to the Saudi Arabia flag if you want.

DakshVohra (3)

could you put hindi?

rjlevy (345)

Hi @DakshVohra, thanks for the suggestion. I've added Hindi 👍

ZDev1 (533)


Also I don't prefer to use bodyParser
You can use only express.json() and express.urlencoded({ extended: false })

rjlevy (345)

Hi @ZDev1, thanks for pointing out the error. It was working fine until last night. Do you have any suggestions on how to fix this error?

@vitalets/[email protected]' is not in the npm registry.

rjlevy (345)

I tried removing the node modules with rm -rf node_modules and reinstalling them but I get the same error...

rjlevy (345)

Hi @ZDev1, I reverted to a previous commit from the Github repo and it's now working again 👍

rjlevy (345)

@ZDev1 what alternative to bodyParser do you prefer?

ZDev1 (533)

@rjlevy I used bodyParser in the old version of express
Now you can use express itself instead of bodyParser in the new version
Like:

const express = require('express');
const app = express();

app.use(express.urlencoded({ extended: false; }));
// The code
rjlevy (345)

Hi @ZDev1, that's great & thanks for explaining. I didn't know this was possible. I'm going to try to implement it as you've suggested 👍

rjlevy (345)

Hi @ZDev1, I've removed bodyParser and implemented your suggestion - thanks again 👍

ZDev1 (533)


There are some errors!

rjlevy (345)

@NDLFOREVER thanks. The fun part was getting the flag emojis to work 😁

k9chelsea2 (614)

nice, I speak 2 languages fluently and am learning another one, since I spend most of my days on repl.it at the moment trying to learn c++ and get better at css, I tend to have a repl window open when I'm doing other stuff like trying to learn German it will be much easier to access this repl than go through the trouble of googling google translate this is so much easier than it lol

rjlevy (345)

Hi @NDLFOREVER, that's great to hear. I haven't done any C++ but I've done quite a lot of CSS. I admire you for learning German and happy to hear you can do your translation through repl.it now. Let me know if you have any suggestions to improve the app :)