This week, I started on refactorising the software code. The main purpose of refactoring is due to the current large chuck of repeating codes in different files. Thus, my responsibility is to refactor these codes into a single separate component file, which will then be included in all subsequent user files. If done well, the software will be more maintainable in the future, as most of the enhancements and changes can be done in the component file without changing the structure of the user file.

I started out by reading some documentation provided by the VueJs community. After gaining a basic concept of how Vue components work, I planned out roughly on how the structure of the code should be after refactorisation. To build the code into smaller components, I decided to build general components and then customise them using v-slot directives. This is a built-in feature provided by VueJs framework. I realise that code refactoring is indeed technically more challenging compared to developing enhancements, as refactoring requires a more thorough understanding of the whole system and a well-planned structure.

My supervisor provided me some feedback that my testing on the software was rather inadequate, with many assumptions made. He pointed out that there are positive and negative testing respectively. Negative testing is the difficult one as engineers are trying to break the system by pushing it to the limit. With that done, we will be able to determine the safe range where the system will operate to its desirable behavior. This conversation with my supervisor is rather eye-opening as it leaves me with many aspects to think about.

Categories: Experiential


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.