Return to search

Applying the SOLID principles to JavaScript’s React library

React is as of 2020 one of, if not the most popular JavaScript libraryfor developing web- and mobile applications since its release in 2013. Since the library is so new, there is still much unexplored potential in how we can use React with different programming styles. This project seeks to explore React from an object-oriented point of view, by incorporating the five SOLID design principles in a React application. The SOLID design principles are mainly practices with object-oriented programming and are well established in the object-oriented community for promoting clean and reusable code that is easy to maintain and expand. By rewriting an existing React application to adhere to the SOLID principles, this project aims to analyse if the principles makes the code better, worse or something in between.  The code was rewritten and analysed from different points of views, looking at measurable values by incorporating a metrics suite forobject- oriented programming, and by looking at how the code had improved in terms of expandability and maintenance by trying to add and remove features from the application. The result showed that the rewritten application displayed an improvement of both measurable quality in general and also better potential when it came to maintenance and expandability.  The results suggest that by incorporating the SOLID principles we can use an object-oriented approach when developing React, and it can even give the code a higher level of quality.

Identiferoai:union.ndltd.org:UPSALLA1/oai:DiVA.org:uu-454677
Date January 2021
CreatorsTrodin, Matilda
PublisherUppsala universitet, Institutionen för informationsteknologi
Source SetsDiVA Archive at Upsalla University
LanguageEnglish
Detected LanguageEnglish
TypeStudent thesis, info:eu-repo/semantics/bachelorThesis, text
Formatapplication/pdf
Rightsinfo:eu-repo/semantics/openAccess
RelationUPTEC IT, 1401-5749 ; 21037

Page generated in 0.0021 seconds