Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

JavaScript for Shiny Users

rstudio::conf 2020

by Garrick Aden-Buie

๐Ÿ—“๏ธ January 27 and 28, 2020
โฐ 09:00 - 17:00
๐Ÿจ Continental Ballroom Room 6 (Ballroom Level)

Workshop Links

Workshop Files and Resources


Shiny gives users a powerful toolkit to create interactive web applications. As a result, Shiny users are also web developers! Inevitably, an intermediate Shiny user will want to create a visualization or user interface that isn't available in the shiny package. Fortunately, we can use the building blocks of the web -- JavaScript, HTML, and CSS -- to extend Shiny's capabilities and create engaging Shiny apps.

This two-day, hands-on workshop will introduce Shiny users to JavaScript, the ubiquitous scripting language that powers the modern web. We will explore JavaScript's syntax and will discover its functional programming style to be refreshingly familiar to tidyverse R users. We will learn how to use JavaScript to manipulate HTML and how Shiny uses JavaScript to communicate between the browser and Shiny server. Together, we will build an htmlwidget and as we learn how to incorporate our own or packaged JavaScript code into Shiny apps and RMarkdown documents, and how to simultaneously manage JavaScript and R dependencies.

Learning objectives

Attendees will learn basic JavaScript and how to use JavaScript to manipulate HTML and CSS in interactive webpages. We will explore how to use JavaScript effectively in Shiny apps using htmlwidgets and htmltools. We delve into how Shiny uses JavaScript to build engaging Shiny apps.

Is this course for me?

This workshop is for the Shiny user who boldly waded into the Customizing Shiny section of and quickly wished they had more experience with JavaScript. This user recognizes the benefits of learning JavaScript, but she is overwhelmed by the sheer number of packages, tutorials, and StackOverflow questions that exist in the world. The goal of this workshop is to meet the Shiny user where they are now to learn the best parts of JavaScript that will provide the most value and facilitate learning and exploration after the workshop.


๐Ÿ‘ฉโ€๐Ÿ’ป Please follow the instructions at to get started.

We will spend most of our time in this workshop in RStudio and a web browser. RStudio Desktop is preferred because we will occasionally need to run commands like npm in your computer's terminal or console.

I recommend the Firefox, Firefox Developer Edition, or Chrome browsers and will use Firefox during the workshop.


We have a lot planned for our time together, so the topics listed below provide a general overview and may change. The times are certain and fixed (unless the rstudio::conf schedule changes).

Monday, January 27

Time Activity
09:00 - 10:30 ๐ŸŽฌ Web Dev 101
10:30 - 11:00 โ˜• Coffee break
11:00 - 12:30 ๐Ÿ’… Interactivity and Style
12:30 - 13:30 ๐Ÿฑ Lunch break
13:30 - 15:00 โšก JavaScript
15:00 - 15:30 โ˜• Coffee break
15:30 - 17:00 ๐ŸŒ R for Web Dev

Tuesday, January 28

Time Activity
09:00 - 10:30 ๐Ÿ“ฆ htmlwidgets
10:30 - 11:00 โ˜• Coffee break
11:00 - 12:30 โ˜Ž๏ธ Communicating with Shiny
12:30 - 13:30 ๐Ÿฑ Lunch break
13:30 - 15:00 ๐Ÿ‘ฏโ€โ™€๏ธ Extending Shiny
15:00 - 15:30 โ˜• Coffee break
15:30 - 17:00 ๐Ÿคนโ€โ™€๏ธ Building Awesome Shiny Apps


Garrick Aden-Buie is an RStudio certified trainer and a data scientist at the Moffitt Cancer Center in the Collaborative Data Services Core where he uses and trains others to use R, Shiny, and the tools of data science to accelerate research towards the prevention and cure of cancer.

This work is licensed under a Creative Commons Attribution 4.0 International License.