Summary
In this chapter, we’ve described what an SPFx library component is and how to use it to mutualize common code and avoid duplication. We’ve detailed the library creation and linking process with other solutions through a practical example. Finally, we’ve compared library components to npm packages, seen another way to reuse code across solutions, and provided guidance on when to choose what, depending on your scenario.
In the next chapter, we’ll detail how to debug your SPFx solutions efficiently for all types of components.