connect wix website to a server

I tried to create a js file in the backend but received the following error in the code:
‘require’ is not defined