Discussion on Streamlining ScriptTag Functionalities and Data Wrangling Strategies
During this meeting, the State Changers discussed a complication with script tagging which led to the creation of a function that provides up-to-date statistics, but also presented some challenges. The scenario presented involved user input changing a value within a web form, with each input creating a new key-value pair that was being pushed to a global array. The issue at hand was wanting to only update and send the last input instead of all the inputs.
To solve this the State Changers discussed different methods, considering either creating the matrix only once or only allowing the last input to win. They demonstrated their problem and solution with a tangible example, using numbers in alternating fields. The ultimate aim was to get the last value inputted into each field.
To accomplish this, they used code to create a prop object for each input, but the order of input allowed the last input to override the previous ones, ensuring only the last inputs were stored. They also made sure this could repeatedly run for testing purposes.
They considered pushing this process to the backend for the sake of efficiency. The State Changers concluded that it is often more beneficial to focus on making the code simpler and easier to understand, rather than strictly focusing on efficiency. They ended the meeting looking forward to future collaboration.