better dynamic snippet for keys