-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Should theme
argument in page_*()
functions accept a string?
#1067
Comments
I think the ship has probably sailed at this point for accepting a string. We also do throw an informative error: > bslib::page("bar", theme = "foo")
Error in assert_bs_theme(theme) : `theme` must be a `bs_theme()` object |
Strange, I tested on both the CRAN version and the latest github version of {bslib}, and |
Ahh, right, that error only gets thrown when rendered statically. Otherwise, it gets passed to |
The other side of this would be to allow a string value for Clearly throwing an error would be easier, but I think we should contemplate alternatives before implementing. |
What is meant by "static rendering"? What is the dynamic rendering version of the code I gave above |
I think Carson means printing |
In shiny's page functions, the
theme
argument can accept either abs_theme()
object or a path to a CSS file.In bslib's page functions, the documentation says that the only acceptable value is a
bs_theme()
object. However, it seems that providing a string path to a CSS file also works. Should this be accepted or no? If yes, it should be documented. If no, an error should get thrown.The text was updated successfully, but these errors were encountered: