1.0.2 • Published 3 years ago

react-tradingview-technical-analysis v1.0.2

Weekly downloads
7
License
ISC
Repository
github
Last release
3 years ago

react-tradingview-technical-analysis

React component for rendering the https://www.tradingview.com/widget/technical-analysis/

Using the components

1) From the command line inside of your project:

npm install --save react-tradingview-technical-analysis

2) Import the component to your project

import TechnicalAnalysis from 'react-tradingview-technical-analysis';

3) Use as if it was any other component
<TechnicalAnalysis
	symbol={'ETH'} 
/>

Props

NameTypeDefault ValueValues
autoSizeboolfalsetrue, false
colorThemeenumlightlight, dark
containerIdstringtradingview-widget-containerAny Container Id
heightnumber450Any Number
intervalenum1m1m, 5m, 15m, 1h, 4h, 1W, 1M
isTransparentboolfalsetrue, false
localestringenAny Locale Code
showIntervalTabsbooltruetrue, false
symbolstringRequired PropAny Symbol
widthnumber425Any Number

Exmaples:

Example with props:
import TechnicalAnalysis from 'react-tradingview-technical-analysis';

render() {
...
<TechnicalAnalysis
	symbol={'ETH'} 
    interval={TechnicalAnalysis.THEMES.ONE_HOUR}
    autoSize={true}
/>
...
import TechnicalAnalysis from 'react-tradingview-technical-analysis';

render() {
...
<TechnicalAnalysis
	symbol={'ETH'} 
    colorTheme ={TechnicalAnalysis.THEMES.DARK}
/>
...
Example with exported constants:
import TechnicalAnalysis, { THEMES, INTERVALS} from 'react-tradingview-technical-analysis';

render() {
...
<TechnicalAnalysis
	symbol={'ETH'} 
    colorTheme ={THEMES.DARK}
    interval={INTERVALS.ONE_WEEK}
/>
...