Skip to content
This repository was archived by the owner on Jun 3, 2024. It is now read-only.

Commit 22c5cc1

Browse files
author
Ryan Patrick Kyle
committed
+ if (require(dash))
1 parent 4eb3b35 commit 22c5cc1

File tree

1 file changed

+24
-24
lines changed

1 file changed

+24
-24
lines changed

dash-info.yaml

+24-24
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ r_examples:
1414
- name: dccChecklist
1515
dontrun: FALSE
1616
code: |
17-
if (interactive()) {
17+
if (interactive() && require(dash)) {
1818
library(dash)
1919
library(dashHtmlComponents)
2020
library(dashCoreComponents)
@@ -38,7 +38,7 @@ r_examples:
3838
- name: dccInterval
3939
dontrun: FALSE
4040
code: |
41-
if (interactive()) {
41+
if (interactive() && require(dash)) {
4242
library(dash)
4343
library(dashHtmlComponents)
4444
library(dashCoreComponents)
@@ -89,7 +89,7 @@ r_examples:
8989
- name: dccSlider
9090
dontrun: FALSE
9191
code: |
92-
if (interactive()) {
92+
if (interactive() && require(dash)) {
9393
library(dash)
9494
library(dashCoreComponents)
9595
library(dashHtmlComponents)
@@ -127,7 +127,7 @@ r_examples:
127127
- name: dccConfirmDialog
128128
dontrun: FALSE
129129
code: |
130-
if (interactive()) {
130+
if (interactive() && require(dash)) {
131131
library(dash)
132132
library(dashCoreComponents)
133133
library(dashHtmlComponents)
@@ -164,7 +164,7 @@ r_examples:
164164
- name: dccLink
165165
dontrun: FALSE
166166
code: |
167-
if (interactive()) {
167+
if (interactive() && require(dash)) {
168168
library(dash)
169169
library(dashCoreComponents)
170170
library(dashHtmlComponents)
@@ -196,7 +196,7 @@ r_examples:
196196
- name: dccStore
197197
dontrun: FALSE
198198
code: |
199-
if (interactive()) {
199+
if (interactive() && require(dash)) {
200200
library(dashCoreComponents)
201201
library(dashHtmlComponents)
202202
library(dash)
@@ -241,7 +241,7 @@ r_examples:
241241
app$callback(
242242
output(id = i, property = 'data'),
243243
params = list(
244-
input(id = sprintf('%s-button', i), property = 'n_clicks'),
244+
input(id = paste0(i, '-button'), property = 'n_clicks'),
245245
state(id = i, property = 'data')
246246
),
247247
function(n_clicks, data){
@@ -261,7 +261,7 @@ r_examples:
261261
262262
for (i in c('memory', 'local', 'session')) {
263263
app$callback(
264-
output(id = sprintf('%s-clicks', i), property = 'children'),
264+
output(id = paste0(i, '-clicks'), property = 'children'),
265265
params = list(
266266
input(id = i, property = 'modified_timestamp'),
267267
state(id = i, property = 'data')
@@ -285,7 +285,7 @@ r_examples:
285285
- name: dccConfirmDialogProvider
286286
dontrun: FALSE
287287
code: |
288-
if (interactive()) {
288+
if (interactive() && require(dash)) {
289289
library(dash)
290290
library(dashCoreComponents)
291291
library(dashHtmlComponents)
@@ -324,7 +324,7 @@ r_examples:
324324
- name: dccLoading
325325
dontrun: FALSE
326326
code: |
327-
if (interactive()) {
327+
if (interactive() && require(dash)) {
328328
library(dash)
329329
library(dashCoreComponents)
330330
library(dashHtmlComponents)
@@ -372,7 +372,7 @@ r_examples:
372372
- name: dccTab
373373
dontrun: FALSE
374374
code: |
375-
if (interactive()) {
375+
if (interactive() && require(dash)) {
376376
library(dash)
377377
library(dashCoreComponents)
378378
library(dashHtmlComponents)
@@ -409,7 +409,7 @@ r_examples:
409409
- name: dccDatePickerRange
410410
dontrun: FALSE
411411
code: |
412-
if (interactive()) {
412+
if (interactive() && require(dash)) {
413413
library(dash)
414414
library(dashCoreComponents)
415415
@@ -428,7 +428,7 @@ r_examples:
428428
- name: dccLocation
429429
dontrun: FALSE
430430
code: |
431-
if (interactive()) {
431+
if (interactive() && require(dash)) {
432432
library(dash)
433433
library(dashCoreComponents)
434434
library(dashHtmlComponents)
@@ -462,7 +462,7 @@ r_examples:
462462
- name: dccTabs
463463
dontrun: FALSE
464464
code: |
465-
if (interactive()) {
465+
if (interactive() && require(dash)) {
466466
library(dash)
467467
library(dashCoreComponents)
468468
library(dashHtmlComponents)
@@ -499,7 +499,7 @@ r_examples:
499499
- name: dccDatePickerSingle
500500
dontrun: FALSE
501501
code: |
502-
if (interactive()) {
502+
if (interactive() && require(dash)) {
503503
library(dash)
504504
library(dashCoreComponents)
505505
@@ -517,7 +517,7 @@ r_examples:
517517
- name: dccLogoutButton
518518
dontrun: FALSE
519519
code: |
520-
if (interactive()) {
520+
if (interactive() && require(dash)) {
521521
library(dash)
522522
library(dashCoreComponents)
523523
@@ -532,7 +532,7 @@ r_examples:
532532
- name: dccTextarea
533533
dontrun: FALSE
534534
code: |
535-
if (interactive()) {
535+
if (interactive() && require(dash)) {
536536
library(dash)
537537
library(dashCoreComponents)
538538
@@ -552,7 +552,7 @@ r_examples:
552552
- name: dccDropdown
553553
dontrun: FALSE
554554
code: |
555-
if (interactive()) {
555+
if (interactive() && require(dash)) {
556556
library(dash)
557557
library(dashCoreComponents)
558558
@@ -576,7 +576,7 @@ r_examples:
576576
- name: dccMarkdown
577577
dontrun: FALSE
578578
code: |
579-
if (interactive()) {
579+
if (interactive() && require(dash)) {
580580
library(dash)
581581
library(dashHtmlComponents)
582582
library(dashCoreComponents)
@@ -610,7 +610,7 @@ r_examples:
610610
- name: dccUpload
611611
dontrun: FALSE
612612
code: |
613-
if (interactive()) {
613+
if (interactive() && require(dash)) {
614614
library(dash)
615615
library(dashCoreComponents)
616616
library(dashHtmlComponents)
@@ -677,7 +677,7 @@ r_examples:
677677
- name: dccGraph
678678
dontrun: FALSE
679679
code: |
680-
if (interactive()) {
680+
if (interactive() && require(dash)) {
681681
library(dash)
682682
library(dashCoreComponents)
683683
library(plotly)
@@ -725,7 +725,7 @@ r_examples:
725725
- name: dccRadioItems
726726
dontrun: FALSE
727727
code: |
728-
if (interactive()) {
728+
if (interactive() && require(dash)) {
729729
library(dash)
730730
library(dashHtmlComponents)
731731
library(dashCoreComponents)
@@ -750,7 +750,7 @@ r_examples:
750750
- name: dccInput
751751
dontrun: FALSE
752752
code: |
753-
if (interactive()) {
753+
if (interactive() && require(dash)) {
754754
library(dash)
755755
library(dashHtmlComponents)
756756
library(dashCoreComponents)
@@ -772,7 +772,7 @@ r_examples:
772772
- name: dccRangeSlider
773773
dontrun: FALSE
774774
code: |
775-
if (interactive()) {
775+
if (interactive() && require(dash)) {
776776
library(dash)
777777
library(dashHtmlComponents)
778778
library(dashCoreComponents)

0 commit comments

Comments
 (0)