I like to get the url with hashtag with the r GET function from the httr package
httr::GET("https://en.wikipedia.org/wiki/Kona_Lanes#Peak_years")
However only the url before the hashtag is returned.
Another example is the following. The results for the "first" and "second" page are
library(httr)
url1 = "example.com"
url2 = "example.com#foo=bar"
res1 <- htmlTreeParse(GET(paste("https://www.",url1,sep="") ),useInternalNodes = TRUE)
res2 <- htmlTreeParse(GET(paste("https://www.",url2,sep="")),useInternalNodes = TRUE)