Can anyone tell me if ever you implemented a code in JS, did replit gave error while compiling the function “prompt or alert”? I tried on a different complier they both are working but in replit, it’s not recognizing them as function.
Replit Profile: https://replit.com/@gound2002
You mean using the
alert functions in Node.js?
Yes I mean those functions that you mentioned
In Node.js has no built-in
alert functions, but you can use other similar functions instead.
Instead of the
alert function, you should use the
To use the
prompt function in Node.js you should use the
prompt('Enter your name:')
As I was following this youtuber, he was able to execute both of them on replit
Most likely, he used an old version of the Node template.the js in which these functions were.
Do you know as to why did they remove these functions or did they limit the use of all library functions only to the pro version?
I have no information about why this was done.
No one said that these functions are limited to the pro plan. The
prompt functions are also unavailable for pro users without additional installation.
oh, thank you so much for the info
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.