<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Hinesh Patel on Medium]]></title>
        <description><![CDATA[Stories by Hinesh Patel on Medium]]></description>
        <link>https://medium.com/@hineshpatel0?source=rss-20a7d413f08c------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*Gv50szlc2IGNQQAd.</url>
            <title>Stories by Hinesh Patel on Medium</title>
            <link>https://medium.com/@hineshpatel0?source=rss-20a7d413f08c------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 14 Nov 2026 20:53:22 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@hineshpatel0/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[From concept to reality: clinic retest results]]></title>
            <link>https://tech.sh24.org.uk/from-concept-to-reality-clinic-retest-results-309995d7603f?source=rss-20a7d413f08c------2</link>
            <guid isPermaLink="false">https://medium.com/p/309995d7603f</guid>
            <category><![CDATA[ruby-on-rails]]></category>
            <category><![CDATA[domain-driven-design]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[software-design]]></category>
            <dc:creator><![CDATA[Hinesh Patel]]></dc:creator>
            <pubDate>Wed, 29 May 2024 14:53:49 GMT</pubDate>
            <atom:updated>2024-05-29T14:53:49.551Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hUrwUI9zB35DFkY3nsOqSw.jpeg" /></figure><p>When a service user completes a blood test, there are some reactive results which require the service user to be sent to a clinic for a retest. As the system stands, we store these retest results for all HIV tests. Last week we were hit with a feature request to roll this out across all other blood tests.</p><p>In this blog, I will outline the approach we took and how we applied concepts of Domain Driven Design to do so.</p><h3>How do we model referring Service Users for a clinic retest?</h3><p>When a service user receives an reactive blood test result, we refer them to a clinic to get a retest, and then the clinic report the results back to us.</p><p>We need to break this down into requirements:</p><ul><li>When the Service User receives an reactive blood test result, we refer them to a clinic for a retest.</li><li>The clinic reports the retest result back to us and we store this against the Service User’s order.</li><li>The referral to clinic only applies to blood tests.</li><li>Should be compatible with any future blood test types.</li></ul><p>Let’s map this out on a diagram:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/723/1*mPlRqzHyf52yfJVSmA0smQ.png" /><figcaption>Clinic Retest Flow</figcaption></figure><p>From the diagram above, we can begin to workout how we can implement this:</p><ul><li>Upon the first reactive result being delivered to the user, we can create a clinic retest result, with either a blank result or a result which represents a “default” state.</li><li>Keep the default state until more information is received.</li><li>The retest result has been received and is logged in our systems — update the clinic retest result to the correct result.</li></ul><p>With the above, let’s update our diagram:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*2b7JOd_ogXXlKaelE3QfUg.png" /><figcaption>Updated Clinic Retest Flow</figcaption></figure><p>A few assumptions:</p><ul><li>At some point, the user will attend the clinic. If this does not take place, the retest result will stay in the default state indefinitely.</li><li>The default state is set automatically but once the retest has been done, this will be updated manually by a system user.</li><li>Once it has been updated by a system user, it will not be changed again. Of course, unusual circumstances like incorrect results can happen, but in this case the retest result will not be updated via the UI.</li></ul><h3>Database Structure</h3><p>Armed with the above requirements, we can now create the database structure:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/942/1*mOQ4IJg_jv1FQ7GnVKjqHQ.png" /><figcaption>Database ER Diagram</figcaption></figure><p>With this underlying database structure, we can use this to build our UI.</p><p>To summarise: take the feature, think closely around where each small part fits into the larger domain; this small amount of fore-thought makes the implementation easier and ultimately faster too.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=309995d7603f" width="1" height="1" alt=""><hr><p><a href="https://tech.sh24.org.uk/from-concept-to-reality-clinic-retest-results-309995d7603f">From concept to reality: clinic retest results</a> was originally published in <a href="https://tech.sh24.org.uk/">SH:24 Product &amp; Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ViewComponents For UI Happiness]]></title>
            <link>https://tech.sh24.org.uk/viewcomponents-for-ui-happiness-a4d8ba59f840?source=rss-20a7d413f08c------2</link>
            <guid isPermaLink="false">https://medium.com/p/a4d8ba59f840</guid>
            <category><![CDATA[ruby-on-rails]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[viewcomponents]]></category>
            <category><![CDATA[rails]]></category>
            <category><![CDATA[ruby]]></category>
            <dc:creator><![CDATA[Hinesh Patel]]></dc:creator>
            <pubDate>Wed, 14 Feb 2024 09:46:02 GMT</pubDate>
            <atom:updated>2024-02-14T10:04:57.589Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1011/1*k0LpeQ_Rbvx1mO8Nxqnsdg.jpeg" /></figure><p>At SH:24, we use ViewComponents in most aspects of our UI. It has helped us to make reusable UI elements, and have a consistent UI across our application.</p><h3>What is ViewComponents?</h3><p><a href="https://github.com/ViewComponent/view_component">ViewComponents</a> is a framework for building and testing reusable UI components. According to the <a href="https://viewcomponent.org/">documentation</a>, ViewComponents is an evolution of the presenter pattern, inspired by <a href="https://react.dev/">React</a>.</p><h3>Why we use ViewComponents?</h3><h4>Single responsibility</h4><p>In the worst case, Rails scatters logic across views, models, controllers, services and helpers, this can make it hard to follow logical chains and distinguish what is responsible for what.</p><p>With ViewComponents, all the logic related to a particular view is encapsulated within a ViewComponent, which can then be added to any part of your application.</p><h4>Testing</h4><p>As all the logic is encapsulated within a ViewComponent, we can write separate and uncomplicated unit tests for a ViewComponent, with special cases covered at a unit test level. This also allows us to leverage the Capybara matchers library too.</p><p>We’re now free to test the end-to-end assertions in integration or feature tests, without checking for the pesky special cases covered by the unit tests.</p><p>These ViewComponent unit tests are also quick. As mentioned in the ViewComponents documentation: “In the GitHub codebase, ViewComponent unit tests are over 100x faster than similar controller tests”.</p><h4>Reusable</h4><p>One of the biggest reasons why we use ViewComponents is the ability for us to create reusable UI components across the application. This allows us to have a standardised UI across the application, and also helps us to build an internal design system and style guide.</p><h3>How do you implement a ViewComponent?</h3><p>Let’s take a look at this simple view below, which renders a header and a list of blog posts:</p><pre>h1 This is the header for my BlogPost website<br>- @posts.each do |post|<br>  p= post.title</pre><p>We can move the part which renders the blog post list into a ViewComponent. First, we will create the ViewComponent ruby class:</p><pre># app/components/post_list/component.rb<br><br>class PostList::PostList::Component &lt; ApplicationComponent<br>  def initialize(posts:)<br>    @posts = posts<br>  end<br>end</pre><p>Now we have the class, we can move the view logic, within this directory:</p><pre>#app/components/post_list/component.html.slim<br><br>- @posts.each do |post|<br>  p= post.title</pre><p>We can now replace the post lists, in our view, to render this newly created component:</p><pre>h1=&quot;This is the header for my BlogPost website&quot;<br>= render(PostList::Component.new(posts: @posts))</pre><p>This allows us, to drop the PostList::Component anywhere in our application, and the UI is consistent throughout!</p><h3>So, should you use ViewComponents?</h3><p>There are a few cons to using the ViewComponents library:</p><ul><li>As ViewComponents is a separate gem, it does mean adding another dependency to the applications, and setting this up. However, the setup is not complex.</li><li>You can do encapsulate view logic, using partials, service classes and presenters. However, unit testing this logic separately is tricky. This is not an issue with ViewComponents.</li></ul><p>We’ve definitely found that the pros of using ViewComponents outweigh any cons, as encapsulating view logic in a separate area of the app is good for maintenance, reusability and overall developer happiness!</p><p>Have you used ViewComponents in your applications? Do you prefer partials? Something else? Start a (respectful) argument in the comments!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a4d8ba59f840" width="1" height="1" alt=""><hr><p><a href="https://tech.sh24.org.uk/viewcomponents-for-ui-happiness-a4d8ba59f840">ViewComponents For UI Happiness</a> was originally published in <a href="https://tech.sh24.org.uk/">SH:24 Product &amp; Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Brighton Ruby 2023]]></title>
            <link>https://tech.sh24.org.uk/brighton-ruby-2023-68be2f33aedf?source=rss-20a7d413f08c------2</link>
            <guid isPermaLink="false">https://medium.com/p/68be2f33aedf</guid>
            <category><![CDATA[ruby]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[brighton]]></category>
            <category><![CDATA[conference]]></category>
            <dc:creator><![CDATA[Hinesh Patel]]></dc:creator>
            <pubDate>Tue, 22 Aug 2023 09:59:27 GMT</pubDate>
            <atom:updated>2023-08-22T09:59:27.420Z</atom:updated>
            <content:encoded><![CDATA[<p>Some members of the Product and Engineering team at SH:24 attended Brighton Ruby 2023 (<a href="https://brightonruby.com/">https://brightonruby.com/</a>) at the end of June. We had an amazing day out and learned a lot that we could bring back to SH:24.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9RWkRHIckgRy8CECgxtXBQ.png" /><figcaption>The team, 2023</figcaption></figure><h3>What is Brighton Ruby?</h3><p>Brighton Ruby is a Ruby conference held in Brighton, England. The day comprised a single track event of talks, as well as a great opportunity to speak to the sponsors and, of course, a whole lot of other people who use Ruby in different ways.</p><h3>Why did we decide to go?</h3><p>Personal development and training is very important. I went last year as part of a smaller team and we soon realised everyone could benefit from attending, and besides, it’s a day away from our desks and a chance to meet in person; a rarity as a fully remote team.</p><h3>Highlights</h3><h4>The importance of documentation — Kaitlyn Tierney</h4><p>I’ll talk about three talks that leapt out at me specifically: the first of which was around documentation. I’m pretty sure most developers would agree it’s something we tend to neglect, and also I probably wouldn’t be alone saying it’s one of the less fun parts of our job.</p><p>However, this talk really opened my eyes as to why we should keep documentation at the forefront of everything we do, as well as being a good guide on how to get started. The speaker demoed the layouts they use and showed us the importance of accessibility, as well as how quickly and easily you can take small steps to achieve it, like adding clear titles and headings.</p><h4>Hanami 2.0 — Tim Riley</h4><p>Hanami is another framework built with Ruby. This talk demoed the new features of Hanami 2.0 and it was done in the style of Ricky Martin! The way it was demoed was through the evolution of the song Livin’ la Vida Loca. It was a unique take, to put it mildly!</p><p>What stood out for me was how conceptually different it was to Ruby on Rails. I’m not sure if it’s yet mature enough to adopt at scale, but Hanami is gaining traction and I can see it potentially kicking off in the future.</p><h4>Game writing using Ruby — Joe Hart</h4><p>This talk was interesting and involved a lot of audience participation. The speaker played Pacman on stage, playing as the titular Pacman, and the audience were all ghost characters. All done by connecting to a server from our phones and playing live. It was an amazing way to end the conference, and proved Ruby had the chops to do something massive(ish)-ly multiplayer.</p><p>There was one key message which the speaker mentioned that stood out to me: “Build anything, but build it for fun”.</p><h3>What I got out of the day</h3><p>Even though the talks were excellent, and I enjoyed discussing them with the team, I think the thing that hit me most was a new optimism for the Ruby language and my career in general.</p><p>It is often loudly announced that Ruby is a dying language. But after attending this conference it made me realise that Ruby is well and truly alive, and the future is still bright for this language.</p><h3>What the team got out of the day</h3><p>I asked the team, to write one highlight from the day. Here are their responses:</p><ul><li><em>A great day out catching up with the team again</em></li><li><em>Loved the talk on documentation</em></li><li><em>Left with a boost of ruby enthusiasm! A fun day with the team</em></li></ul><p>As a fully distributed remote team, we often don’t meet up for months on end. Going to Brighton Ruby was a chance for us all to meet up in person, have some lunch, catch a drink after the conference and reflect on both the day, and how we can apply what we have learned to our day-to-day life at SH:24. Additionally, a team member was leaving the company, and attending this conference was a great way for us to send them off in a social, offline way. Perfect!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=68be2f33aedf" width="1" height="1" alt=""><hr><p><a href="https://tech.sh24.org.uk/brighton-ruby-2023-68be2f33aedf">Brighton Ruby 2023</a> was originally published in <a href="https://tech.sh24.org.uk/">SH:24 Product &amp; Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How we pair program as a remote team]]></title>
            <link>https://tech.sh24.org.uk/how-we-pair-program-as-a-remote-team-c1cc353eb483?source=rss-20a7d413f08c------2</link>
            <guid isPermaLink="false">https://medium.com/p/c1cc353eb483</guid>
            <category><![CDATA[remote-pair-programming]]></category>
            <category><![CDATA[pair-programming]]></category>
            <category><![CDATA[team-collaboration]]></category>
            <category><![CDATA[remote-working]]></category>
            <dc:creator><![CDATA[Hinesh Patel]]></dc:creator>
            <pubDate>Thu, 06 Oct 2022 15:57:19 GMT</pubDate>
            <atom:updated>2022-10-14T14:52:06.638Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*o-EXRh62Vv1wF6hGc8enkg.jpeg" /></figure><p>Pair programming is a common working practice in software engineering. It involves two or more developers working together on a given problem. Usually, programmers would sit in front of the same computer.</p><p>Here at SH:24, the development team is a fully remote and distributed team. And pair programming can be challenging sometimes but we make it work.</p><h4>Utilising huddles in Slack</h4><p>The huddle tool in Slack has been amazing for us, and has changed the way we work. Whenever we are stuck on a problem, and want some help, depending on what we are working on. We would either shout on in the wider team channel or shout out in our sub team channel.</p><p>Once someone is available, we would start a huddle on the team channel and get pairing. Where possible, we always try to do huddles on the team channels, as anyone can jump in if they are curious</p><h4>Driver and navigator role</h4><p>When we pair program we use the driver and navigator role. Simply put, the driver writes the code, and the navigator reviews the code and plans. We find this works seamlessly while working remotely.</p><p>When pairing with junior members of the team. Where possible, we always try to let them be the navigator.</p><p>Every 30 minutes or so, we switch roles to get different perspectives.</p><h3>Benefits of pair programming</h3><h4>Consistent feedback</h4><p>The person writing the code (the driver) receives constant feedback. As the code is written in a collaborative way.</p><h4>Less frustration</h4><p>We have all been there, we have been trying to crack a problem for a long time and not getting anywhere. What better way to crack this, than getting a fresh pair of eyes onto the problem?</p><h4>Focus</h4><p>When pair programming, there are no distractions, as you and your pairing partners will be so engrossed in the problem. Which, in turn, leads (sometimes) to more productivity.</p><h4>Social interaction</h4><p>Remote working can get lonely, pair programming allows you to work with others. Also, it gets you talking and communicating with others, which always helps.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c1cc353eb483" width="1" height="1" alt=""><hr><p><a href="https://tech.sh24.org.uk/how-we-pair-program-as-a-remote-team-c1cc353eb483">How we pair program as a remote team</a> was originally published in <a href="https://tech.sh24.org.uk/">SH:24 Product &amp; Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>