How to show/hide invisible files and folders from Service menu?

Apologies if this is a little off-topic from your question, but, in macOS Sierra you can toggle showing hidden files right in the Finder with Shift+cmd+.