I don't believe you will be able to at 3.1. The LocateButton class was not added until version 3.7. See the following link:https://developers.arcgis.com/javascript/jsapi/locatebutton-amd.html
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.