formats.js is used both on the server and on the client. The client needs it to know what formats to display for the format chooser, and for the ladder. The server needs it to know what rules to enforce when you select a format.
As for port forwarding, you're most likely also using the wrong IP address. After port forwarding, to connect to your server from the internet, you'll need your public IP address (in other words, the IP address of your router). Services such as whatismyip.org will tell you.
Yes, it's possible to host PS on Heroku. I just spent the last few hours figuring it out. Host it there and connect to: