Home Reference Source
public class | source

Timer

Extends:

react~React.Component → Timer

This component shows a simple timer, the timer update the time showed every 50ms

Member Summary

Public Members
public

This variable is used to stop the forceUpdate when the component is unmounted

Method Summary

Public Methods
public

When the component is mounted, force the refresh every 50ms

public

When the component is about to be unmounted, stop the refresh

public

render(): XML

Render

Public Members

public forceUpdateInterval: number source

This variable is used to stop the forceUpdate when the component is unmounted

Public Methods

public componentDidMount() source

When the component is mounted, force the refresh every 50ms

public componentWillUnmount() source

When the component is about to be unmounted, stop the refresh

public render(): XML source

Render

Return:

XML