Просмотр исходного кода

Declare htmlwidgets dependencies

master
Garrick Aden-Buie 6 лет назад
Родитель
Сommit
969fd962ed
2 измененных файлов: 24 добавлений и 7 удалений
  1. +18
    -0
      dev/dev.Rmd
  2. +6
    -7
      inst/htmlwidgets/frappeChart.yaml

+ 18
- 0
dev/dev.Rmd Просмотреть файл

usage, this is also where we'll put code that would let us update the usage, this is also where we'll put code that would let us update the
widget in place without having to re-render the whole chart. widget in place without having to re-render the whole chart.
To create the htmlwidget,
we're going to work through each of these pieces
and put them in the right places.

# Make it an htmlwidget

## Declare dependencies

**FILE:** `inst/htmlwidgets/frappeChart.yaml`

Take the `htmltools::htmlDependency()` and
turn it into `inst/htmlwidgets/frappeChart.yaml`.

```{r}
rstudioapi::navigateToFile("inst/htmlwidgets/frappeChart.yaml")
```

Note: keep `htmlwidgets` in `src`!

+ 6
- 7
inst/htmlwidgets/frappeChart.yaml Просмотреть файл

# (uncomment to add a dependency)
# dependencies:
# - name:
# version:
# src:
# script:
# stylesheet:
dependencies:
- name: "frappe-charts"
version: "1.3.0"
src: "htmlwidgets/lib/frappe-charts"
script: "frappe-charts.min.iife.js"
all_files: TRUE

Загрузка…
Отмена
Сохранить