Skip to content

Instantly share code, notes, and snippets.

@Ryshackleton
Last active August 27, 2020 20:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Ryshackleton/95ff84c7c145369cfe9b3a559a26162d to your computer and use it in GitHub Desktop.
Save Ryshackleton/95ff84c7c145369cfe9b3a559a26162d to your computer and use it in GitHub Desktop.
const scrollyTellerConfiguration = { // Section Configuration object
// event handler triggered when text box reaches 50% of page height
onActivateNarrationFunction: function ({
// section configuration containing a reference to a graph component
sectionConfig: { graph },
// state = JSON.parse(trigger)
state: { year },
}) {
if (graph && year) {
graph.render({ year });
}
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment