Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
),
avatarStyle: {
type: UrlQueryParamTypes.string,
updateType
}
}
export class Renderer extends React.Component {
static childContextTypes = {
optionContext: PropTypes.instanceOf(OptionContext)
}
static defaultProps = {
avatarStyle: AvatarStyle.Circle
}
private optionContext: OptionContext = new OptionContext(allOptions)
getChildContext () {
return { optionContext: this.optionContext }
}
componentWillReceiveProps (nextProps: Props) {
this.updateOptionContext(nextProps)
}
componentWillMount () {
this.updateOptionContext(this.props)
}
componentDidMount () {
const anyWindow = window as any
setTimeout(() => {
export class Main extends React.Component {
static childContextTypes = {
optionContext: PropTypes.instanceOf(OptionContext)
}
static defaultProps = {
avatarStyle: AvatarStyle.Circle
}
state = {
displayComponentCode: false,
displayComponentImg: false
}
private avatarRef: Avatar | null = null
private canvasRef: HTMLCanvasElement | null = null
private optionContext: OptionContext = new OptionContext(allOptions)
getChildContext () {
return { optionContext: this.optionContext }
}
componentWillReceiveProps (nextProps: Props) {
this.updateOptionContext(nextProps)
}
componentWillMount () {
this.optionContext.addValueChangeListener(this.onOptionValueChange)
this.updateOptionContext(this.props)
}
componentDidMount () {
const anyWindow = window as any