<?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 Kotchakorn Siriprasertwit on Medium]]></title>
        <description><![CDATA[Stories by Kotchakorn Siriprasertwit on Medium]]></description>
        <link>https://medium.com/@k.siriprasertwit?source=rss-6e753ae5725c------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*GPF8BYurdAIOyaiLcuhzFw.jpeg</url>
            <title>Stories by Kotchakorn Siriprasertwit on Medium</title>
            <link>https://medium.com/@k.siriprasertwit?source=rss-6e753ae5725c------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 17:04:34 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@k.siriprasertwit/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[PromptNow Coding Style Agreements]]></title>
            <link>https://medium.com/@k.siriprasertwit/promptnow-coding-style-agreements-f6dbf205a934?source=rss-6e753ae5725c------2</link>
            <guid isPermaLink="false">https://medium.com/p/f6dbf205a934</guid>
            <category><![CDATA[swiftlint]]></category>
            <category><![CDATA[swift]]></category>
            <dc:creator><![CDATA[Kotchakorn Siriprasertwit]]></dc:creator>
            <pubDate>Wed, 08 May 2019 10:51:33 GMT</pubDate>
            <atom:updated>2023-08-28T06:49:23.441Z</atom:updated>
            <content:encoded><![CDATA[<h3>Coding Style Agreements</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*3jXNphGURJqGPTWl-Sky7g.png" /><figcaption>Source: <a href="https://www.pinclipart.com/pindetail/iRRJThx_my-swift-note-swift-programming-language-logo-clipart/">Pinclipart</a></figcaption></figure><h3>SwiftLint</h3><p>A tool to enforce Swift style and conventions, loosely based on <a href="https://github.com/github/swift-style-guide">GitHub’s Swift Style Guide</a>.</p><h3>Instructions</h3><ol><li>Install SwiftLint:</li></ol><pre>pod &#39;SwiftLint&#39;</pre><p>2. Add Run Script to Build Phases:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*JMyJmeyHeVuEE7CU.png" /></figure><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e576e189a4e6a1b93c521167bdbbdaca/href">https://medium.com/media/e576e189a4e6a1b93c521167bdbbdaca/href</a></iframe><p>3. Copy <a href="https://trello-attachments.s3.amazonaws.com/5c81f7685392e87350de8191/5cb82d31bc957c4c80216596/44a9851410f4869ff27a69c6f64e9fa1/.swiftlint.yml">.swiftlint.yml</a> to Project’s Directory</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*BMOTSd1XVl2CmTtU.png" /></figure><p>4. Build It!!!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*AVakPJfkiydHvS_x.png" /></figure><h3>Naming</h3><h4><strong>Outlets</strong></h4><ul><li>use camel case</li><li>start with action/name follow by type of outlets</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/babdc89f9e74be709a6f0a8aaf28e22a/href">https://medium.com/media/babdc89f9e74be709a6f0a8aaf28e22a/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/63b25d1d8641aacd0de17c75401045b5/href">https://medium.com/media/63b25d1d8641aacd0de17c75401045b5/href</a></iframe><h4><strong>Enumerations (Enum)</strong></h4><ul><li>use camel case</li><li>keyword start with capital letter</li><li>case start with lowercase letter</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e172da24ce6da18170cd202008ccd400/href">https://medium.com/media/e172da24ce6da18170cd202008ccd400/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/526bb664d3dde5305afe6e519370f5cc/href">https://medium.com/media/526bb664d3dde5305afe6e519370f5cc/href</a></iframe><h4><strong>Functions</strong></h4><ul><li>use camel case</li><li>start with lowercase letter</li><li>naming with what it does</li><li>argument label parameter is optional for more readable code</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1c61b97326bb8cfc4bfd475c268f4713/href">https://medium.com/media/1c61b97326bb8cfc4bfd475c268f4713/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/14eacb770adcde3b97dfdb5ce2d8f845/href">https://medium.com/media/14eacb770adcde3b97dfdb5ce2d8f845/href</a></iframe><h4><strong>TypeAlias</strong></h4><ul><li>use camel case</li><li>keyword start with capital letter</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4cbdfb33b1c0e5d1c467e0dbd369f6f6/href">https://medium.com/media/4cbdfb33b1c0e5d1c467e0dbd369f6f6/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2d94968fcb7c0cbb026d606b2256c212/href">https://medium.com/media/2d94968fcb7c0cbb026d606b2256c212/href</a></iframe><h4><strong>Folder</strong></h4><ul><li>start with capital letter</li><li>use camel case</li><li>non space between words</li></ul><p>Example</p><ul><li>Module</li><li>Register</li><li>ContactUs</li><li>BillPayments</li></ul><h4>Model Service</h4><ul><li>start with capital letter</li><li>use camel case</li><li>start with service no. , main path and service name</li><li>if name is abbreviation, use upper case</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e217d317be9906bb8c38f42b440a1176/href">https://medium.com/media/e217d317be9906bb8c38f42b440a1176/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/cd78ca965a7b1e7a827606b6f5f42c24/href">https://medium.com/media/cd78ca965a7b1e7a827606b6f5f42c24/href</a></iframe><h3><strong>Statements</strong></h3><h4><strong>Spacings</strong></h4><ul><li>use 1 space before any brackets ({ })</li></ul><p>Example</p><ul><li><strong>if else</strong></li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/a51a9da86f64cd503011f49ae4302c44/href">https://medium.com/media/a51a9da86f64cd503011f49ae4302c44/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/48faef3afcd3ef90233bdeddc4cd76be/href">https://medium.com/media/48faef3afcd3ef90233bdeddc4cd76be/href</a></iframe><ul><li><strong>switch case</strong></li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/6a1ddb1dddd6f93a21a59e698d844574/href">https://medium.com/media/6a1ddb1dddd6f93a21a59e698d844574/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/07b289807a6c07f0406a94058f6e10a1/href">https://medium.com/media/07b289807a6c07f0406a94058f6e10a1/href</a></iframe><h4><strong>Colon (:)</strong></h4><ul><li>use colon after parameter without space</li><li>use 1 space before type annotations</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/2407483906fe98d07e11a6a3ebf0dcb5/href">https://medium.com/media/2407483906fe98d07e11a6a3ebf0dcb5/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/016cbd1fdbe39148d54cdfd53bd8baf5/href">https://medium.com/media/016cbd1fdbe39148d54cdfd53bd8baf5/href</a></iframe><h3><strong>Memory Management</strong></h3><h4><strong>Closures</strong></h4><ul><li>use weak references (eg. [weak self]) to not keep a strong reference instance and can be deallocated</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/11f57f57ab7a5e60f8f4905528cc3fee/href">https://medium.com/media/11f57f57ab7a5e60f8f4905528cc3fee/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/bc43c2b6f3bb88f21fec6627a6f5a439/href">https://medium.com/media/bc43c2b6f3bb88f21fec6627a6f5a439/href</a></iframe><h4><strong>Protocols</strong></h4><ul><li>declare delegates as weak references to prevent reference cycles</li></ul><p>Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f3ca6e0cb2e72527d770940142b78214/href">https://medium.com/media/f3ca6e0cb2e72527d770940142b78214/href</a></iframe><p>Not Preferred:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/40c7ac41334f2d12a1bbc2d103c3ec5c/href">https://medium.com/media/40c7ac41334f2d12a1bbc2d103c3ec5c/href</a></iframe><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f6dbf205a934" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>