Forum Discussion
Using AngularJS in Custom Visual
- 7 years ago
Your code above is almost correct. You can also learn how to pass props in React Doc.
ReactDOM.render(React.createElement(App, {options}), this.element);You should also add options as props into App.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
Hey Ignat thanks for that, it's an interesting alternative, I'll let you know how it works out (you might get another question for react :-) )
Happy to help.
Current samplkes does not look good since it does not use modern ES2015 features such as modules but we're working on webpack based pbiviz to bring new features to developers.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- MikeAinOz7 years agoHelper V
Ignat, I can't figure out how to get the dataView into the React Component.
I'm doing this is in Update:
ReactDOM.render(React.createElement(App, options), this.element);but what do I do in the App.tsx? I've managed to pass a test string, but how to pass the VisualUpdateOptions object?Having had a play with React, it looks like a good way to create Custom Visuals- v-viig7 years agoCommunity Champion
Your code above is almost correct. You can also learn how to pass props in React Doc.
ReactDOM.render(React.createElement(App, {options}), this.element);You should also add options as props into App.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- MikeAinOz7 years agoHelper V
I'm having some trouble getting that working. I've run out of time to work on it, but I was thinking of getting a programmer to get the example working for me. Is it worth doing that or will there be something else coming along?