Feb 05 2018 11:21 AM - edited Feb 05 2018 11:28 AM
Howdy Community!
In looking at various SPFx tutorials/samples, I've noticed different paradigms demonstrated for where to locate the ReactJS component code. For example, Patrick Rodgers' tutorial on transitioning to @pnp/sp from sp-pnp-js vs a React sp-pnp-js web part included among the SPFx samples. Both achieve a 'Hello World' flavored SharePoint query, but using very different syntax.
Patrick's example houses the pertinent code within the .ts file, and his project does not even appear to have a .tsx file or /components folder at all. José Quinto's sample, on the other hand, utilizes the componentDidMount function within the .tsx file for the pertinent code.
Feb 05 2018 04:31 PM
SolutionFeb 05 2018 04:31 PM
Solution