# Create contents
my_info <- c("data_path" = "Users/me/documents/my_project/data")
# Generate a local folder for exporting
temp_folder <- tempdir()
# Create a JSON with those contents
make_json(x = my_info, file = file.path(temp_folder, "user.json"), git_ignore = FALSE)
# Read it back in
(user_info <- RJSONIO::fromJSON(content = file.path(temp_folder, "user.json")))
Run the code above in your browser using DataLab