How to implement rainbow trail effect?

Hi guys, I’m wondering how to implement a cool rainbow trail effect as in Robot Unicorn Attack?

Pls watch the video: