Its hard to know how to advise you and fight the fear that we'd be moving you away from good practice to less-good as your ask seems rather vague, it seems like you are asking how to perform an interim step of a larger goal. I believe if we had sight of your larger goal, or typical usecase you wish to address, then the quality of advice we could give you would be greater.
There are extremely convenient ways to work with variables of a dataframe and for example execute the same operation over a few of its variables, therefore can you justify why breaking them out into an an explicit list would seem to be a worthwhile part of your process ?
I saw your message from another topic, but when I finish typing, the original message was deleted, here're my reply to that:
for this situation, it's not that easy to apply a treatment to multiple global-environment variables, I suggest you pre-process the original list then transfer them into vars.
map() is a traversal function from purrr package which can apply a function to each element of a list or atomic vector. In your case, you can try:
base <- base %>% map(
~ .x %>% mutate(
across(where(is.numeric), ~ replace_na(.x, 0)),
across(where(is.character), ~ replace_na(.x, ""))
))
# replace_na() will return same datatype as input, so you can't pass "" to a numeric nor 0 to a character
# then :
for (i in names(base)) assign(i,base[[i]])