First log into your WHM
Once logged into your WHM, in the top left search bar type service and then go to the service configuration.
Once on Service configuration go to Apache Configuration
Go to Include Editor
Once in Include Editor, go under Post VirtualHost Include select All Versions
Now this will open up a text box, and you’ll want to paste this content in it:
Then click on save.
And finally you just need to add this to your .htaccess
RewriteRule ^(css|js)/(.*)\.[0-9]+\.(.*)$ /$1/$2.$3 [L]
And you are good to go. Do some tests at gtmetrix.com and see the magic.