Created
April 19, 2018 10:14
-
-
Save gHashTag/6be3552b239af8cd98555d49af2b951a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react' | |
| import './class.css' | |
| class Classes extends Component { | |
| constructor () { | |
| super() | |
| this.state = { | |
| show: true | |
| } | |
| } | |
| componentDidMount () { | |
| this.addScript() | |
| } | |
| addScript () { | |
| const script = document.createElement('script') | |
| script.src = 'https://widgets.healcode.com/javascripts/healcode.js' | |
| script.async = true | |
| document.body.appendChild(script) | |
| } | |
| show () { | |
| this.state() | |
| } | |
| render() { | |
| return ( | |
| <healcode-widget data-type='schedules' data-widget-partner='object' data-widget-id='473784925a0' data-widget-version='0.1'></healcode-widget> | |
| ) | |
| } | |
| } | |
| export default Classes |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment