React JS bold the text in between
In the below code, I would like to style only some words for chartDesc (for example "the payback period"). Either bold or italic etc. Tried regular expressions, did not work. Please help! import React from 'react'; import Pie from './Pie'; import TextTruncate from 'react-text-truncate'; import ReactTooltip from 'react-tooltip'; import { browserHistory } from 'react-router'; export default class Donutchart extends React.Component { constructor(props) { super(); } getElements(id) { let backendData = this.props.data; let width = 120; let height = 120; let radius = Math.min(width, height) / 2; let
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.