highcharts-react icon indicating copy to clipboard operation
highcharts-react copied to clipboard

Fix build-demo script in package.json and removing unnecessary codes in HighchartsReact.js

Open venkateshsundaram opened this issue 2 years ago • 1 comments

Problem: i)While Running build-demo script in local, it will throw below errors ii)Removing unnecessary codes in HighchartsReact.js

preset-env preset-react error

Solution: i)To avoid above errors, need to change the build-demo script as [ babelify --presets [ @babel/preset-env @babel/preset-react ] ] instead of [ babelify --presets [ env react ] ] ii) a) Restructured props.callback ? props.callback : undefined as props.callback. if props doesn't have callback, default value will be undefined b) chartRef.current removed in else statement. since if statement checked as !chartRef.current, so always chartRef.current will have value in else statement

venkateshsundaram avatar Mar 28 '22 17:03 venkateshsundaram

Hi @ppotaczek . Can you please review this PR

venkateshsundaram avatar Mar 29 '22 04:03 venkateshsundaram

The problem with build-demo script has been fixed in v3.2.0.

ppotaczek avatar Mar 01 '23 14:03 ppotaczek