Skip to content

Commit 1034c77

Browse files
committed
Small improvements to widgets vignette
1 parent 66d5dbb commit 1034c77

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

vignettes/intro_htmlwidgets.Rmd

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ usethis::create_package("~/sparklines")
4949
# Inject the widget templating
5050
withr::with_dir(
5151
"~/sparklines",
52-
reactR::scaffoldReactWidget("sparklines", list("react-sparklines" = "^1.7.0"))
52+
reactR::scaffoldReactWidget("sparklines", list("react-sparklines" = "^1.7.0"), edit = FALSE)
5353
)
5454
```
5555

@@ -101,6 +101,8 @@ At this point, we've built some scaffolding for an htmlwidget powered by React.
101101

102102
### First, outline an interface
103103

104+
> Note that the examples in this section are just to demonstrate API possibilities and need not be pasted into any file.
105+
104106
Consider the following example taken from the [react-sparklines documentation](http://borisyankov.github.io/react-sparklines/).
105107

106108
```js
@@ -182,7 +184,7 @@ sparklines <- function(data, ..., width = NULL, height = NULL) {
182184
}
183185
```
184186

185-
At this point, we define functions that make it easy for the user to create the other components by adding these to `R/reactSparklines.R`
187+
At this point, we define functions that make it easy for the user to create the other components by adding these to `R/sparklines.R`
186188

187189
```{r}
188190
#' @export

0 commit comments

Comments
 (0)