Ask coding questions

← Back to all posts
How can i make run other file in JS?
andressamb

Example: I have one file name index.js
then i create another with the name aula2.js
when i use the file aula2.js the console just reads the index file.
how can i make read the other one?

Voters
andressamb
Comments
hotnewtop
NFadhlurrahman

The run command in the .replit file should be

andressamb

@NFadhlurrahman I forgot to change there. but it's still the same, it doesnt read. i put the same code in the others files and it's still reading just the index.js page.

NFadhlurrahman

@andressamb Remove the semicolon in the .replit file.