<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Content-Creation on dev.endevour</title><link>https://devendevour.iankulin.com/tags/content-creation/</link><description>Recent content in Content-Creation on dev.endevour</description><generator>Hugo</generator><language>en-AU</language><lastBuildDate>Fri, 23 Sep 2022 00:00:00 +0000</lastBuildDate><atom:link href="https://devendevour.iankulin.com/tags/content-creation/index.xml" rel="self" type="application/rss+xml"/><item><title>Gists for embedding code</title><link>https://devendevour.iankulin.com/gists-for-embedding-code/</link><pubDate>Fri, 23 Sep 2022 00:00:00 +0000</pubDate><guid>https://devendevour.iankulin.com/gists-for-embedding-code/</guid><description>&lt;p&gt;So, I might have found a slightly better method for sharing code in posts that I complained about the &lt;a href="https://devendevour.iankulin.com/wordpress-code-blocks/"&gt;other day&lt;/a&gt; . GitHub has a thing called &lt;a href="https://gist.github.com/" target="_blank" rel="noopener"&gt;Gists&lt;/a&gt; . It&amp;rsquo;s like a tiny repository you can paste a code snippet into (or upload a source file). Once that&amp;rsquo;s done, you can just paste the URL of the Gist into &lt;a href="https://wordpress.com/support/gist/" target="_blank" rel="noopener"&gt;Wordpress&lt;/a&gt; - it recognises it and does this:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-swift" data-lang="swift"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;ForEach(&lt;span style="color:#ae81ff"&gt;0.&lt;/span&gt;.&amp;lt;&lt;span style="color:#ae81ff"&gt;3&lt;/span&gt;) { number &lt;span style="color:#66d9ef"&gt;in&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; Button {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#75715e"&gt;// flag was tapped&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; flagTapped(number)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; } label: {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; FlagView(flagOf: countries[number])
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; .rotation3DEffect(.degrees(flagSpinAmount[number]),
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; axis: (x: &lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;, y: &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;, z: &lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;))
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; .opacity(flagOpacity[number])
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; .scaleEffect(flagScale[number])
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; .animation(.&lt;span style="color:#66d9ef"&gt;default&lt;/span&gt;, value: flagSpinAmount)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I came across this being used on a &lt;a href="https://blog.rosay.io/create-a-camera-app-with-swiftui-60876fcb9118" target="_blank" rel="noopener"&gt;blog post&lt;/a&gt; (about using the camera in apps) from &lt;a href="https://rosay.io/" target="_blank" rel="noopener"&gt;Gaspard Rosay&lt;/a&gt; .&lt;/p&gt;</description></item><item><title>Sometimes the Gold is in the Comments</title><link>https://devendevour.iankulin.com/sometimes-the-gold-is-in-the-comments/</link><pubDate>Tue, 23 Aug 2022 00:00:00 +0000</pubDate><guid>https://devendevour.iankulin.com/sometimes-the-gold-is-in-the-comments/</guid><description>&lt;p&gt;I&amp;rsquo;m still not 100% clear on @ObservedObject v @StateObject. So when YouTube offered up this video, in which Paul promises during the intro that I&amp;rsquo;ll understand the data bindings by the end, I thought it would be the video for me.&lt;/p&gt;
&lt;div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"&gt;
 &lt;iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share; fullscreen" loading="eager" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube.com/embed/stSB04C4iS4?autoplay=0&amp;amp;controls=1&amp;amp;end=0&amp;amp;loop=0&amp;amp;mute=0&amp;amp;start=0" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" title="YouTube video"&gt;&lt;/iframe&gt;
 &lt;/div&gt;

&lt;p&gt;I guess I should really have twigged that I&amp;rsquo;d never heard of @ObjectBinding, but I pushed on to the 12 minute mark when he imports the &lt;em&gt;Combine&lt;/em&gt; framework. Hang on, what&amp;rsquo;s that?&lt;/p&gt;</description></item></channel></rss>