NetCod NetCod - 1 month ago 8
Swift Question

labels on images in ios like instagram

UIimageview with label

In iOS 10 ( Swift 2) how would I go about getting a tag on an image like Instagram does in the pic below ? I want to get the 'topgearporsche" label and get it on the right object in this case - the porsche for an app I am building.

Thanks in advance.

Answer

This is pretty basic.

image.addSubview(label)