There are many functions for manipulating strings in R. One example is the stringr package that is part of the tidyverse. In the example below, I take a vector where each element is two words and I change it to keep only the first word of each element. The regular expression "^[:alpha:]+" means: "from the start of the text, look for one or more alphabetic characters". A space is not an alphabetic character, so the function searches up to the first space. Perhaps this will work for your needs.
library(stringr)
#> Warning: package 'stringr' was built under R version 3.5.3
NAMES <- c("Aera Mowaslkd", "Ciouc Lsieldkdfj", "Duionecd Ldfosd ")
NAMES <- str_extract(NAMES, "^[:alpha:]+")
NAMES
#> [1] "Aera" "Ciouc" "Duionecd"
Created on 2019-11-09 by the reprex package (v0.3.0.9000)