Unable to get Terms from TermStore in SPFx

%3CLINGO-SUB%20id%3D%22lingo-sub-1900665%22%20slang%3D%22en-US%22%3EUnable%20to%20get%20Terms%20from%20TermStore%20in%20SPFx%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1900665%22%20slang%3D%22en-US%22%3E%3CP%3EI%20need%20to%20retrieve%20term%20set%20hierarchy%20in%20the%20SPFx%20solution.%20I%20have%20tested%20all%20the%20suggestions%2C%20but%20none%20work.%20Has%20anyone%20managed%20to%20retrieve%20terms%20in%20the%20SPFx%3F%3C%2FP%3E%3CP%3EAny%20tips%20and%20suggestions%20would%20be%20appreciated.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1927723%22%20slang%3D%22en-US%22%3ERe%3A%20Unable%20to%20get%20Terms%20from%20TermStore%20in%20SPFx%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1927723%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F873264%22%20target%3D%22_blank%22%3E%40sharepointkonsult%3C%2FA%3E%26nbsp%3BYou%20should%20try%20the%20PnPJS%20library%20for%20this.%20It%20will%20make%20retrieving%20Taxonomy%20values%20much%20easier.%26nbsp%3B%3CBR%20%2F%3E%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fpnp.github.io%2Fpnpjs%2Fv1%2Fsp-taxonomy%2Fdocs%2Fterm-sets%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fpnp.github.io%2Fpnpjs%2Fv1%2Fsp-taxonomy%2Fdocs%2F%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Occasional Visitor

I need to retrieve term set hierarchy in the SPFx solution. I have tested all the suggestions, but none work. Has anyone managed to retrieve terms in the SPFx?

Any tips and suggestions would be appreciated.

1 Reply

@sharepointkonsult You should try the PnPJS library for this. It will make retrieving Taxonomy values much easier. 

https://pnp.github.io/pnpjs/v1/sp-taxonomy/docs/