How to deploy a directory along with a function?

So it seems according to here if you have the folder as a subdirectory it should just work