<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>rubycoloredglasses</title>
    <description>I&apos;m Jason, a web application developer in East Tennessee.
</description>
    <link>https://www.rubycoloredglasses.com/</link>
    <atom:link href="https://www.rubycoloredglasses.com/feed.xml" rel="self" type="application/rss+xml" />
    <pubDate>Fri, 10 Apr 2026 09:17:14 -0400</pubDate>
    <lastBuildDate>Fri, 10 Apr 2026 09:17:14 -0400</lastBuildDate>
    <generator>Jekyll v3.10.0</generator>
    
      <item>
        <title>Playing Video in your Subaru Starlink System</title>
        <description>&lt;p&gt;If you own a Subaru Outback or Legacy released in 2015 - 2018 that includes
the Starlink system (the one without Apple Carplay), then you might not know
that you can do the following cool things with a USB drive or SD card.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;View a slideshow of images&lt;/li&gt;
  &lt;li&gt;Upload an image to display when you turn the “screen off”&lt;/li&gt;
  &lt;li&gt;Sit back and watch videos while the car is parked (with parking break on)&lt;/li&gt;
&lt;/ul&gt;

&lt;!--more--&gt;

&lt;p&gt;You can find details on how this is done in the
&lt;a href=&quot;https://cdn.subarunet.com/stis/doc/ownerManual/MSA5M1711A_STIS_Index2.pdf&quot;&gt;2017 Legacy and Outback Subaru Starlink Owners Manual&lt;/a&gt;, but I’m here to
extract that and tell you what to do.&lt;/p&gt;

&lt;p&gt;Note: Don’t add files to the navigation/map system SD card, as this will break
the navigation.&lt;/p&gt;

&lt;h2 id=&quot;general&quot;&gt;General&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;The USB thumb drive or SD card should be formatted as FAT 16 or FAT 32&lt;/li&gt;
  &lt;li&gt;Maximum number of folders: 3000&lt;/li&gt;
  &lt;li&gt;Maximum number of files: 9999&lt;/li&gt;
  &lt;li&gt;Maximum files per a folder: 255&lt;/li&gt;
  &lt;li&gt;MP3/WMA/AAC files in folders up to 8 levels deep can be played. However, the
start of playback may be delayed when using discs containing numerous levels
of folders. For this reason, we recommend creating discs with no more than 2
levels of folders.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;music&quot;&gt;Music&lt;/h2&gt;

&lt;p&gt;The player relies on &lt;a href=&quot;https://en.wikipedia.org/wiki/ID3&quot;&gt;ID3&lt;/a&gt; tags included in the files to identify the title
of the artists, album, track, cover art, etc. If you import CDs or MP3 files you
buy on Bandcamp into the Apple Music app, you edit this metadata for your music,
and even apply cover artwork.&lt;/p&gt;

&lt;p&gt;The manual states that the Starlink system supports streaming audio from iPod
devices (classic, iPod Touch 1st - 5th gen, iPod nano 1st - 7th gen, iPhone
1 - 5). I’m using an iPhone 14 Pro and it works fine.&lt;/p&gt;

&lt;p&gt;Compatible Files Types:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;MP3 - ‘.mp3’ extension&lt;/li&gt;
  &lt;li&gt;WMA - ‘.wma’ extension&lt;/li&gt;
  &lt;li&gt;AAC - ‘.m4a’ extension&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;video&quot;&gt;Video&lt;/h2&gt;

&lt;p&gt;Ensure to engage the parking brake when watching video content, otherwise you
will only get a blue video thumbnail.&lt;/p&gt;

&lt;p&gt;iPod video is not supported.&lt;/p&gt;

&lt;p&gt;The following video codecs are supported:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;WMV9 - WMV or AVI file type&lt;/li&gt;
  &lt;li&gt;MPEG4 - MPEG4 or AVI file type&lt;/li&gt;
  &lt;li&gt;H.264/AVC - MPEG4 or AVI file type&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The following video resolutions are supported:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href=&quot;https://en.wikipedia.org/wiki/Low-definition_television#Resolutions&quot;&gt;Low definition television&lt;/a&gt;
    &lt;ul&gt;
      &lt;li&gt;128×96 (MMS-Small - Lowest size recommended for use with 3GPP video)&lt;/li&gt;
      &lt;li&gt;160×120 (QQVGA - Lowest commonly used video resolution)&lt;/li&gt;
      &lt;li&gt;176×144 (QCIF Webcam)&lt;/li&gt;
      &lt;li&gt;320×240 (QVGA, NTSC square pixel)&lt;/li&gt;
      &lt;li&gt;352×240 (SIF (525) - NTSC-standard VCD / super-long-play DVD)&lt;/li&gt;
      &lt;li&gt;352×288 (CIF / SIF (625) - PAL-standard VCD / super-long-play DVD)&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://en.wikipedia.org/wiki/480p#Resolutions&quot;&gt;480p&lt;/a&gt;
    &lt;ul&gt;
      &lt;li&gt;640×480 (480p - 4:3 ratio)&lt;/li&gt;
      &lt;li&gt;720×480 (480p - 3:2 ratio)&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://en.wikipedia.org/wiki/576p&quot;&gt;576p&lt;/a&gt;
    &lt;ul&gt;
      &lt;li&gt;720×576 (considered standard definition for PAL regions)&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you are using a Mac, I recommend using &lt;a href=&quot;https://handbrake.fr/&quot;&gt;Handbrake&lt;/a&gt; to convert your videos.
I used the “Fast 480p30” and “Fast 576p25” presets in Handbrake to convert
videos and they worked just fine.&lt;/p&gt;

&lt;h2 id=&quot;images&quot;&gt;Images&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;The compatible photo file extensions are JPG and JPEG.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;slideshow&quot;&gt;Slideshow&lt;/h2&gt;

&lt;p&gt;You can view a slideshow of images if you are parked with the emergency parking
break engaged. From the “INFO” menu the USB drive or SD card will show up as
an option, select that option. A menu will display (e.g. “USB Photo”) with
options shown to display a Slide Show, with Play Time (Fast, Normal Slow) and
Play Mode (Normal, Random) options.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Image files can be viewed at the same time that audio files are being played
back.&lt;/li&gt;
  &lt;li&gt;Ensure to engage the parking brake when watching video content. If not, only a
blue screen will be displayed. Audio, however, can be heard normally.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;screen-off&quot;&gt;Screen Off&lt;/h3&gt;

&lt;p&gt;You can set an image as the screen off images by uploading images from a USB
drive or SD card.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;When saving the images to a USB or SD card, make sure to place them in an
‘Image’ folder located in the root folder of the drive. If this folder name
is not used, the system cannot download the images. The folder name
is case sensitive.&lt;/li&gt;
  &lt;li&gt;Go to Home &amp;gt; Settings &amp;gt; General, then tap “Customize Screen Off Image”&lt;/li&gt;
  &lt;li&gt;After you’ll uploaded the images to your system, you can go to Home &amp;gt;
Settings &amp;gt; Screen Off to make your console display the “Screen Off” image.&lt;/li&gt;
&lt;/ul&gt;
</description>
        <pubDate>Sat, 16 Sep 2023 17:53:00 -0400</pubDate>
        <link>https://www.rubycoloredglasses.com/2023/09/subaru-starlink-video-photos/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2023/09/subaru-starlink-video-photos/</guid>
        
        <category>subaru</category>
        
        <category>starlink</category>
        
        <category>video</category>
        
        <category>photos</category>
        
        
        <category>Miscellaneous</category>
        
      </item>
    
      <item>
        <title>Generating Jekyll Posts from an External Source</title>
        <description>&lt;p&gt;I want to use a headless CMS with Jekyll as the source of my blog posts.
There aren’t many plugins that aim to faciliate this.&lt;/p&gt;

&lt;p&gt;There is a &lt;a href=&quot;https://import.jekyllrb.com/docs/wordpress/&quot;&gt;WordPress jekyll-import&lt;/a&gt; tool, but this is intended for a one
time import of Wordpress content to Markdown files inside of your Jekyll
project, not a continual build process that sources all content from an API.&lt;/p&gt;

&lt;!--more--&gt;

&lt;h2 id=&quot;the-jekyll-engine&quot;&gt;The Jekyll Engine&lt;/h2&gt;

&lt;p&gt;Jekyll Posts are just a natively supported form of &lt;a href=&quot;https://jekyllrb.com/docs/collections/&quot;&gt;Jekyll collection&lt;/a&gt;. The
documentation for Jekyll even states that if you configure your “collections” to
load from a different directory, you will need to move your &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_posts&lt;/code&gt; and
&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_drafts&lt;/code&gt; folder under that directory as well.&lt;/p&gt;

&lt;p&gt;Jekyll builds your site through a process that involves the following steps:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Read - Reads data from directories/files into the &lt;a href=&quot;https://github.com/jekyll/jekyll/blob/d86ba153f/lib/jekyll/site.rb&quot;&gt;Jekyll::Site&lt;/a&gt; object&lt;/li&gt;
  &lt;li&gt;Generate - Runs each of the Generators defined by plugins you’ve installed or
coded yourself&lt;/li&gt;
  &lt;li&gt;Render - Renders content in memory (markdown converted to HTML, SASS converted
to CSS, etc.)&lt;/li&gt;
  &lt;li&gt;Cleanup - Removes orphaned files and empty directories in destination&lt;/li&gt;
  &lt;li&gt;Write - Writes static files, pages, and posts to build directory
(e.g. &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_site&lt;/code&gt;)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The entire process is about “reading” data from files into Ruby objects that are
stored inside of the &lt;a href=&quot;https://github.com/jekyll/jekyll/blob/d86ba153f/lib/jekyll/site.rb&quot;&gt;Jekyll::Site&lt;/a&gt; object. This includes pages, posts,
collections, and data.&lt;/p&gt;

&lt;p&gt;After this it runs the generators defined by Jekyll plugins you install, or that
you write yourself.&lt;/p&gt;

&lt;p&gt;Next it goes through a rendering process, where the content loaded from Markdown
files is converted to HTML. For instance, inside of each &lt;a href=&quot;https://github.com/jekyll/jekyll/blob/d86ba153f/lib/jekyll/document.rb#L34,L62&quot;&gt;Jeyll::Document&lt;/a&gt;
object used to represent each blog post, the Markdown is stored to the
‘content’ attribute, but the rendered HTML is stored in the ‘output’ attribute.&lt;/p&gt;

&lt;p&gt;The cleanup step performs the necessary file cleaning up in the site destination
directory.&lt;/p&gt;

&lt;p&gt;Lastly all the rendered data is then written to actual files under the
destination directory (e.g. defaults to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_site&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;Here’s how I inspected objects in memory through each step of the site building
process using IRB.&lt;/p&gt;

&lt;div class=&quot;language-ruby highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;nb&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;jekyll&apos;&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;options&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;source&quot;&lt;/span&gt;      &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;File&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;expand_path&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;.&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;),&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;destination&quot;&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;File&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;expand_path&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;./_site&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;),&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;incremental&quot;&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;kp&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;profile&quot;&lt;/span&gt;     &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;kp&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;watch&quot;&lt;/span&gt;       &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;kp&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
  &lt;span class=&quot;s2&quot;&gt;&quot;serving&quot;&lt;/span&gt;     &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;kp&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# merge build options with configuration data&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;options&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;Jekyll&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;configuration&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;options&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# initialize the site object&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;Jekyll&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;::&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;options&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;class&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; Jekyll::Site&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# initialize attribute defaults&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;reset&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# read data from directories/files&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;read&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# inspect posts collection&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;collections&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;posts&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;].&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;class&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; Jekyll::Collection&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;collections&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;posts&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;].&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;docs&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;count&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; 163&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;collections&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;posts&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;].&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;docs&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;0&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; #&amp;lt;Jekyll::Document _posts/2004-09-09-bug-tracking.md collection=posts&amp;gt;&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;path&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; &quot;/Developer/redconfetti.github.io/_posts/2004-09-09-bug-tracking.md&quot;&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;type&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; :posts&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;data&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; {&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;draft&quot;=&amp;gt;false,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;categories&quot;=&amp;gt;[&quot;php&quot;],&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;layout&quot;=&amp;gt;&quot;post&quot;,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;published&quot;=&amp;gt;true,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;title&quot;=&amp;gt;&quot;PHP/MySQL Bug Tracking&quot;,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;author&quot;=&amp;gt;&quot;maxwell keyes&quot;,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;date&quot;=&amp;gt;2004-09-09 16:51:00 -0400,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;comments&quot;=&amp;gt;true,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;tags&quot;=&amp;gt;[&quot;bug tracking&quot;],&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;slug&quot;=&amp;gt;&quot;bug-tracking&quot;,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;ext&quot;=&amp;gt;&quot;.md&quot;,&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;#   &quot;excerpt&quot;=&amp;gt;&amp;lt;Jekyll::Excerpt id=/2004/09/bug-tracking#excerpt&amp;gt;&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# }&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;permalink&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; nil&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Content is the markdown string&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;content&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; &quot;For anyone who needs a free web based Bug Tracking system programmed&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# using\nPHP/MySQL, check out Flyspray.\n&quot;&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;output&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; nil&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# After file content is loaded into Jekyll::Site, it is rendered from Markdown&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# to actual HTML using site.render&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;render&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; nil&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;example_doc&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;output&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# =&amp;gt; &quot;&amp;lt;!DOCTYPE html&amp;gt;\n&amp;lt;html&amp;gt;\n  &amp;lt;head&amp;gt;\n  &amp;lt;meta charset=\&quot;utf-8\&quot;&amp;gt;\n  &lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;lt;meta name=\&quot;viewport\&quot; content=\&quot;width=device-width initial-scale=1\&quot; /&amp;gt;\n&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;lt;meta http-equiv=\&quot;X-UA-Compatible\&quot; content=\&quot;IE=edge\&quot;&amp;gt;\n\n&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;lt;title&amp;gt;PHP/MySQL Bug Tracking&amp;lt;/title&amp;gt;&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# ...&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;lt;footer class=\&quot;footer\&quot;&amp;gt;\n  &amp;lt;span class=\&quot;footer__copyright\&quot;&amp;gt;&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;amp;copy; 2023 Jason Miller. All rights reserved.&amp;lt;/span&amp;gt;\n&amp;lt;/footer&amp;gt;\n\n&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# &amp;lt;/body&amp;gt;\n&amp;lt;/html&amp;gt;\n&quot;&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;cleanup&lt;/span&gt;

&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;write&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;custom-post-approach&quot;&gt;Custom Post Approach&lt;/h2&gt;

&lt;p&gt;I tried to write a plugin/generator for Jekyll that used a class that inherits
from Jekyll::Document, and patches various methods so that it can be used
without sourcing data from a Markdown file under the &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_posts&lt;/code&gt; directory. I was
not able to get this to work without errors and complications.&lt;/p&gt;

&lt;p&gt;Instead, it’s better that you create a custom page template, as suggested by
the &lt;a href=&quot;https://jekyllrb.com/docs/plugins/generators/&quot;&gt;Jekyll Generators&lt;/a&gt; documentation, with a generator that locates the
custom page by name, and simply adds the custom data under the pages &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;data&lt;/code&gt;
hash attribute.&lt;/p&gt;

&lt;h3 id=&quot;liquid-drops&quot;&gt;Liquid Drops&lt;/h3&gt;

&lt;p&gt;The only complication that could not be avoided is that the
&lt;a href=&quot;https://shopify.github.io/liquid/basics/variations/#jekyll&quot;&gt;Liquid templating system&lt;/a&gt; used by Jekyll will raise errors if you use
custom defined objects in your page template
(.e.g &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;undefined method &apos;to_liquid&apos;&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;If the objects you are iterating over and injecting into your page are not
one of the &lt;a href=&quot;https://shopify.github.io/liquid/basics/types/&quot;&gt;basic Ruby types&lt;/a&gt;, then you’ll need to make sure the objects
you’re iterating over inherit from &lt;a href=&quot;https://github.com/Shopify/liquid/blob/main/lib/liquid/drop.rb&quot;&gt;Liquid::Drop&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;See &lt;a href=&quot;https://github.com/Shopify/liquid/wiki/Introduction-to-Drops&quot;&gt;Liquid Drops&lt;/a&gt;&lt;/p&gt;

&lt;h2 id=&quot;wordpress-rss-feed-example&quot;&gt;Wordpress RSS Feed Example&lt;/h2&gt;

&lt;p&gt;Here’s an example of code needed for a simple Jekyll generator that can
retrieve posts from an RSS/XML feed hosted under Wordpress.com.&lt;/p&gt;

&lt;div class=&quot;language-ruby highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;##########################################&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# Gemfile&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# XML to Hash translator&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# https://github.com/savonrb/nori&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;gem&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;nori&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;~&amp;gt; 2.6&apos;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Nokogiri&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# https://github.com/sparklemotion/nokogiri&lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;gem&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;nokogiri&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;~&amp;gt; 1.15&apos;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;# Backport Jekyll Sass Converter to avoid deprecation warnings &lt;/span&gt;
&lt;span class=&quot;n&quot;&gt;gem&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;jekyll-sass-converter&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;~&amp;gt; 2.2&apos;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;##########################################&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# _config.yml&lt;/span&gt;

&lt;span class=&quot;ss&quot;&gt;wp_posts_page:
  title: &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;Blog&apos;&lt;/span&gt;
  &lt;span class=&quot;ss&quot;&gt;layout: &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;wp_posts_page&apos;&lt;/span&gt;
  &lt;span class=&quot;ss&quot;&gt;feed_url: &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;https://redconfetti.wordpress.com/feed/&apos;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;##########################################&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;# _plugins/wordpress_posts.rb&lt;/span&gt;

&lt;span class=&quot;nb&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;net/http&quot;&lt;/span&gt;
&lt;span class=&quot;nb&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;uri&quot;&lt;/span&gt;
&lt;span class=&quot;nb&quot;&gt;require&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;nori&quot;&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;module&lt;/span&gt; &lt;span class=&quot;nn&quot;&gt;WordpressPosts&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;Generator&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;Jekyll&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;::&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Generator&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;generate&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;

      &lt;span class=&quot;vi&quot;&gt;@post_page_config&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;wp_posts_page&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
      &lt;span class=&quot;k&quot;&gt;raise&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;Missing Wordpress configuration in _config.yml&apos;&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;unless&lt;/span&gt; &lt;span class=&quot;vi&quot;&gt;@post_page_config&lt;/span&gt;

      &lt;span class=&quot;n&quot;&gt;page_layout&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;vi&quot;&gt;@post_page_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;layout&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;page_title&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;vi&quot;&gt;@post_page_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;title&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;page_slug&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;page_title&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;strip&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;downcase&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;gsub&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/[\s\.\/\\]/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;-&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;gsub&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/[^\w-]/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;gsub&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/[-_]{2,}/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;-&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;gsub&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/^[-_]/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
        &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;gsub&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/[-_]$/&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;

      &lt;span class=&quot;n&quot;&gt;feed_url&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;vi&quot;&gt;@post_page_config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;feed_url&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;post_feed&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;WordpressFeed&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;feed_url&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;

      &lt;span class=&quot;c1&quot;&gt;# get template&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;posts_page&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;site&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;pages&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;find&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;page&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;page&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;name&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;==&lt;/span&gt; &lt;span class=&quot;s1&quot;&gt;&apos;wp_posts_page.html&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;

      &lt;span class=&quot;n&quot;&gt;posts_page&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;post_feed&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;post_feed&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;items&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;WordpressFeed&lt;/span&gt;
  &lt;span class=&quot;nb&quot;&gt;attr_accessor&lt;/span&gt; &lt;span class=&quot;ss&quot;&gt;:rss_url&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;initialize&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;rss_url&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
    &lt;span class=&quot;nb&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;rss_url&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;rss_url&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;rss_channel&lt;/span&gt;
    &lt;span class=&quot;vi&quot;&gt;@channel&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;begin&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;rss&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;hash_data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;rss&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;rss&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;channel&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;items&lt;/span&gt;
    &lt;span class=&quot;vi&quot;&gt;@item&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;begin&lt;/span&gt;
      &lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;rss_channel&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;item&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]].&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;flatten&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;collect&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;do&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;item&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;
        &lt;span class=&quot;no&quot;&gt;ItemDrop&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;item&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
      &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;kp&quot;&gt;private&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;hash_data&lt;/span&gt;
    &lt;span class=&quot;vi&quot;&gt;@hash_data&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;begin&lt;/span&gt;
      &lt;span class=&quot;k&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;xml_string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;blank?&lt;/span&gt;
        &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;Nori&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;parse&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;xml_string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
      &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;xml_string&lt;/span&gt;
    &lt;span class=&quot;vi&quot;&gt;@xml_string&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||=&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;begin&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;uri&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;URI&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;rss_url&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
      &lt;span class=&quot;no&quot;&gt;Net&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;::&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;HTTP&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;get&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;uri&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;class&lt;/span&gt; &lt;span class=&quot;nc&quot;&gt;ItemDrop&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;&amp;lt;&lt;/span&gt; &lt;span class=&quot;no&quot;&gt;Liquid&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;::&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Drop&lt;/span&gt;
    &lt;span class=&quot;nb&quot;&gt;attr_accessor&lt;/span&gt; &lt;span class=&quot;ss&quot;&gt;:feed_item&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;initialize&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;feed_item&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
      &lt;span class=&quot;nb&quot;&gt;self&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;feed_item&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;feed_item&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;content&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;feed_item&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;content:encoded&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;title&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;feed_item&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;&apos;title&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
&lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Page template (&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;_layouts/wp_posts_page.html&lt;/code&gt;)&lt;/p&gt;

&lt;div class=&quot;language-html highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;---
layout: page
title: Blog
permalink: /blog/
---

&lt;span class=&quot;nt&quot;&gt;&amp;lt;ul&lt;/span&gt; &lt;span class=&quot;na&quot;&gt;style=&lt;/span&gt;&lt;span class=&quot;s&quot;&gt;&quot;list-style-type: none; padding: 0; margin: 0;&quot;&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;&amp;gt;&lt;/span&gt;
  
&lt;span class=&quot;nt&quot;&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;storyblok&quot;&gt;Storyblok&lt;/h2&gt;

&lt;p&gt;The above approach isn’t very ideal due to how Wordpress.com embeds oversized
images into the posts. Also the free Wordpress hosting account limits the
feed to 350 posts.&lt;/p&gt;

&lt;p&gt;Hopefully the above example provides you with enough understanding to obtain
content from any external data source and embed it into your custom Jekyll
pages.&lt;/p&gt;

&lt;p&gt;If you want to go with a free CMS for your own site, consider &lt;a href=&quot;https://www.storyblok.com/&quot;&gt;Storyblok&lt;/a&gt;.
The article, &lt;a href=&quot;https://www.storyblok.com/tp/headless-cms-jekyll&quot;&gt;Add a headless CMS to Jekyll&lt;/a&gt;, gives good instructions on
how to use the &lt;a href=&quot;https://github.com/storyblok/storyblok-ruby-client&quot;&gt;Storyblok Ruby Gem&lt;/a&gt; with Jekyll. With Storyblok you can
define your own schema for the objects you’re embedding in your pages,
and nest the objects inside of the content of other objects.&lt;/p&gt;

</description>
        <pubDate>Sat, 16 Sep 2023 17:31:00 -0400</pubDate>
        <link>https://www.rubycoloredglasses.com/2023/09/generating-jekyll-posts-from-an-external-source/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2023/09/generating-jekyll-posts-from-an-external-source/</guid>
        
        <category>jekyll</category>
        
        <category>generators</category>
        
        <category>posts</category>
        
        <category>cms</category>
        
        
        <category>Ruby</category>
        
      </item>
    
      <item>
        <title>RubyGems SSL Error with jRuby</title>
        <description>&lt;p&gt;I spent several days investigating an error that was coming up with our Rails
application build using jRuby v9.3.3 - v9.3.10. Everytime the build would
try to run &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;bundle install&lt;/code&gt; we would get the following error.&lt;/p&gt;

&lt;!--more--&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;Fetching &lt;span class=&quot;nb&quot;&gt;source &lt;/span&gt;index from https://rubygems.org/
Retrying fetcher due to error &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;2/4&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;: Bundler::HTTPError Could not fetch specs from https://rubygems.org/ due to underlying error &amp;lt;Unrecognized SSL message, plaintext connection? &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;https://rubygems.org/specs.4.8.gz&lt;span class=&quot;o&quot;&gt;)&amp;gt;&lt;/span&gt;

Retrying fetcher due to error &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;3/4&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;: Bundler::HTTPError Could not fetch specs from https://rubygems.org/ due to underlying error &amp;lt;Unrecognized SSL message, plaintext connection? &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;https://rubygems.org/specs.4.8.gz&lt;span class=&quot;o&quot;&gt;)&amp;gt;&lt;/span&gt;

Retrying fetcher due to error &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;4/4&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;: Bundler::HTTPError Could not fetch specs from https://rubygems.org/ due to underlying error &amp;lt;Unrecognized SSL message, plaintext connection? &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;https://rubygems.org/specs.4.8.gz&lt;span class=&quot;o&quot;&gt;)&amp;gt;&lt;/span&gt;

Could not fetch specs from https://rubygems.org/ due to underlying error
&amp;lt;Unrecognized SSL message, plaintext connection?
&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;https://rubygems.org/specs.4.8.gz&lt;span class=&quot;o&quot;&gt;)&amp;gt;&lt;/span&gt;
ERROR: bundle &lt;span class=&quot;nb&quot;&gt;install &lt;/span&gt;failed
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;You will notice it attempts 3 times, this is because the script is actually
running:&lt;/p&gt;

&lt;div class=&quot;language-shell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;bundle &lt;span class=&quot;nb&quot;&gt;install&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--local&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--retry&lt;/span&gt; 3 &lt;span class=&quot;o&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;WARNING: bundle install --local failed, running bundle install&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt; bundle &lt;span class=&quot;nb&quot;&gt;install&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--retry&lt;/span&gt; 3 &lt;span class=&quot;o&quot;&gt;||&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;ERROR: bundle install failed&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;exit &lt;/span&gt;1&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;When we would run our script from the command line, it would work just fine.
When we would try to run it from our Bamboo application (used for Continuous
Integration), it would fail with the above errors.&lt;/p&gt;

&lt;p&gt;We’re using RVM to manage the different Ruby versions needed by our applications
on the Bamboo server. We thought it might be an issue with Bundler, but it
turned out that one of our JAVA configurations was causing this issue.&lt;/p&gt;

&lt;p&gt;We noticed that &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;JAVA_OPTS&lt;/code&gt; was not set when our admin ran the build scripts
from the command line, but with the Bamboo job it was set, and it included
the &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;-Djava.security.properties&lt;/code&gt; option pointing to a file that used the
following:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;jdk.tls.disabledAlgorithms&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;SSLv3, RC4, DES, MD5withRSA, DH keySize &amp;lt; 1024, &lt;span class=&quot;se&quot;&gt;\&lt;/span&gt;
    EC keySize &amp;lt; 224, 3DES_EDE_CBC, anon, NULL, RSASSA-PSS
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;When we added this to the export for JAVA_OPTS, the issue occurred when running
the build scripts, or when running the RubyGems troubleshooting script
(&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;curl -sL https://git.io/vQhWq | ruby&lt;/code&gt;). When we removed it, the error
returned.&lt;/p&gt;
</description>
        <pubDate>Wed, 22 Mar 2023 18:08:51 -0400</pubDate>
        <link>https://www.rubycoloredglasses.com/2023/03/jruby-bundler-unrecognized-ssl-message/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2023/03/jruby-bundler-unrecognized-ssl-message/</guid>
        
        <category>jruby</category>
        
        <category>rubygems</category>
        
        <category>bundler</category>
        
        <category>ssl</category>
        
        
        <category>Ruby</category>
        
      </item>
    
      <item>
        <title>Long time nuclear waste warning messages</title>
        <description>&lt;p&gt;I wanted to apply the robotic voice synthesis to
&lt;a href=&quot;https://en.wikipedia.org/wiki/Long-time_nuclear_waste_warning_messages&quot;&gt;Long-time nuclear waste warning messages&lt;/a&gt;.&lt;/p&gt;

&lt;!--more--&gt;

&lt;div class=&quot;language-shell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;This place is a message&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;and part of a system of messages&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;pay attention to it&lt;/span&gt;&lt;span class=&quot;se&quot;&gt;\!&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;Sending this message was important to us.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;We considered ourselves to be a powerful culture.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;This place is not a place of honor.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;no highly esteemed deed is commemorated here.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;nothing valued is here.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;What is here was dangerous and repulsive to us.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;This message is a warning about danger.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;The danger is in a particular location.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;it increases towards a center.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;the center of danger is here.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;of a particular size and shape, and below us.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;The danger is still present, in your time, as it was in ours.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;The danger is to the body, and it can kill.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;The form of the danger is an emanation of energy.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;The danger is unleashed only if you substantially disturb this place physically.&quot;&lt;/span&gt;
say &lt;span class=&quot;nt&quot;&gt;-v&lt;/span&gt; fred &lt;span class=&quot;s2&quot;&gt;&quot;This place is best shunned and left uninhabited.&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;See also &lt;a href=&quot;https://en.wikipedia.org/wiki/Waste_Isolation_Pilot_Plant&quot;&gt;Warning messages for future humans&lt;/a&gt;&lt;/p&gt;

</description>
        <pubDate>Thu, 09 Dec 2021 15:37:18 -0500</pubDate>
        <link>https://www.rubycoloredglasses.com/2021/12/long-time-nuclear-waste-warning-messages/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2021/12/long-time-nuclear-waste-warning-messages/</guid>
        
        <category>nuclear</category>
        
        <category>waste</category>
        
        <category>warning</category>
        
        
        <category>misc</category>
        
      </item>
    
      <item>
        <title>Updating RBEnv on Raspberry Pi</title>
        <description>&lt;p&gt;Here’s a modified version of instructions provided by &lt;a href=&quot;https://lmlab.net/memo/2021/06/03/use-rbenv-on-raspberrypi.html&quot;&gt;Yosei Ito&lt;/a&gt;. I used
&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;apt remove&lt;/code&gt; instead of &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;apt uninstall&lt;/code&gt;.&lt;/p&gt;

&lt;!--more--&gt;

&lt;div class=&quot;language-ruby highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;n&quot;&gt;sudo&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;apt&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;remove&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;ruby&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;build&lt;/span&gt;
&lt;span class=&quot;err&quot;&gt;$&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;mkdir&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;nb&quot;&gt;p&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;$(rbenv root)&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;plugins&lt;/span&gt;
&lt;span class=&quot;err&quot;&gt;$&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;git&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;clone&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;https&lt;/span&gt;&lt;span class=&quot;ss&quot;&gt;:/&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;github&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;com&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;rbenv&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;ruby&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;build&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;git&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&quot;$(rbenv root)&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;plugins&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;ruby&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;build&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;This worked very well for me, helping me to install Ruby 2.7.3, and install
the gem dependencies for this website without any errors or need for using
‘sudo’ when installing gems via Bundler.&lt;/p&gt;

</description>
        <pubDate>Mon, 14 Jun 2021 10:19:55 -0400</pubDate>
        <link>https://www.rubycoloredglasses.com/2021/06/updating-rbenv-raspberry-pi/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2021/06/updating-rbenv-raspberry-pi/</guid>
        
        <category>raspberrypi</category>
        
        <category>rbenv</category>
        
        
        <category>ruby</category>
        
      </item>
    
      <item>
        <title>Generating a New Rails Project</title>
        <description>&lt;p&gt;The great thing about working with a framework like Ruby on Rails is how you
can pick and choose the components that make up your application. Developers
often have preferences concerning solutions or tools they use in their projects.
They have the choice of testing tools such as &lt;a href=&quot;https://rspec.info/&quot;&gt;Rspec&lt;/a&gt; or &lt;a href=&quot;https://github.com/cucumber/cucumber-rails&quot;&gt;Cucumber&lt;/a&gt;, testing
factory libraries such as &lt;a href=&quot;https://github.com/thoughtbot/factory_bot&quot;&gt;FactoryBot&lt;/a&gt; or &lt;a href=&quot;https://www.fabricationgem.org/&quot;&gt;Fabrication&lt;/a&gt;, authentication
solutions such as &lt;a href=&quot;https://github.com/heartcombo/devise&quot;&gt;Devise&lt;/a&gt; or &lt;a href=&quot;https://github.com/binarylogic/authlogic&quot;&gt;AuthLogic&lt;/a&gt;, and authorization solutions such as
&lt;a href=&quot;https://github.com/ryanb/cancan&quot;&gt;CanCan&lt;/a&gt; or &lt;a href=&quot;https://rubygems.org/gems/pundit&quot;&gt;Pundit&lt;/a&gt;.&lt;/p&gt;

&lt;!--more--&gt;

&lt;p&gt;It can feel heavy having to reconfigure a freshly generated Rails application
to use these different components, because you spend most of your time
configuring the new application rather than jumping into actually building
the functionality.&lt;/p&gt;

&lt;!--more--&gt;

&lt;h2 id=&quot;application-templates&quot;&gt;Application Templates&lt;/h2&gt;

&lt;p&gt;Thankfully Rails supports &lt;a href=&quot;https://guides.rubyonrails.org/rails_application_templates.html&quot;&gt;Application Templates&lt;/a&gt; that make configuring a new
application a breeze.&lt;/p&gt;

&lt;p&gt;It’s possible for you to configure your own custom template with your primary
preferences all in one file. You could maintain your own template in a
&lt;a href=&quot;https://gist.github.com/&quot;&gt;Github Gist&lt;/a&gt; using this option.&lt;/p&gt;

&lt;p&gt;See &lt;a href=&quot;https://gist.github.com/redconfetti/011aac614ebe3bd7d798b431fe789f5a&quot;&gt;my example template&lt;/a&gt;.&lt;/p&gt;

&lt;h3 id=&quot;app-template-command&quot;&gt;App Template Command&lt;/h3&gt;

&lt;p&gt;Even better than this is that you can choose to apply certain configurations
to your application ala carte by using the ‘app:template’ rails command. This
command allows you to run template fragments from publicly hosted template
scripts. You can find many scripts for various solutions on &lt;a href=&quot;https://railsbytes.com/&quot;&gt;Rails Bytes&lt;/a&gt;.&lt;/p&gt;

&lt;h2 id=&quot;my-recipe&quot;&gt;My Recipe&lt;/h2&gt;

&lt;p&gt;I prefer to use tools provided by the JavaScript / ECMAScript eco-system
facilitated by NodeJS packages for my front-end, using Webpack. Ruby on Rails
applications get support for this from &lt;a href=&quot;https://github.com/rails/webpacker#installation&quot;&gt;Webpacker&lt;/a&gt;. I like ReactJS, but I
prefer VueJS for my own personal projects.&lt;/p&gt;

&lt;p&gt;Because I use Webpack as my asset pipeline for the front-end application and
assets, I don’t need the Rails asset-pipeline or page rendering helpers. This
causes me to prefer using an API-only configuration with Ruby on Rails.&lt;/p&gt;

&lt;p&gt;To create a new application, I use the following command to generate an
&lt;a href=&quot;https://guides.rubyonrails.org/api_app.html#creating-a-new-application&quot;&gt;API Application&lt;/a&gt;, using &lt;a href=&quot;https://github.com/rails/webpacker#installation&quot;&gt;Webpacker&lt;/a&gt; to with a VueJS front-end.&lt;/p&gt;

&lt;div class=&quot;language-shell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;rails new my_application &lt;span class=&quot;nt&quot;&gt;--api&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--webpack&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;vue &lt;span class=&quot;nt&quot;&gt;--database&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;sqlite3 &lt;span class=&quot;nt&quot;&gt;--skip-test&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--skip-turbolinks&lt;/span&gt; &lt;span class=&quot;nt&quot;&gt;--skip-sprockets&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;After I’m done generating the application, I use the following application
templates to setup my app.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/V4Yslo&quot;&gt;EditorConfig&lt;/a&gt; - Specifies file formatting guidelines for many code editors&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/z0gsLX&quot;&gt;Rspec&lt;/a&gt; - Popular unit testing framework for Ruby&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/XnJsbX&quot;&gt;FactoryBot&lt;/a&gt; - Fixtures replacement for testing&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/xjNs4x&quot;&gt;StandardRB&lt;/a&gt; - Ruby style guide, linter, and formatter. See &lt;a href=&quot;https://github.com/testdouble/standard&quot;&gt;StandardRB&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/zOvsQ0&quot;&gt;dotenv&lt;/a&gt; - A Ruby gem to load environment variables from &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;.env&lt;/code&gt;.
See &lt;a href=&quot;https://github.com/bkeepers/dotenv&quot;&gt;dotenv-rails&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here are some optional recommendations that depend on the type of application
you are developing:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/VqqsgV&quot;&gt;Friendly ID&lt;/a&gt; - “Swiss Army bulldozer” of slugging and permalink plugins
for Ruby on Rails. See &lt;a href=&quot;https://github.com/eric/friendly_id&quot;&gt;friendly_id&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/V1bs4X&quot;&gt;Ahoy&lt;/a&gt; - Track visits and events in Ruby, JavaScript, and native apps.
Data is stored in your database by default so you can easily combine it with
other data. See &lt;a href=&quot;https://github.com/ankane/ahoy&quot;&gt;Ahoy&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/VWesJz&quot;&gt;PgHero&lt;/a&gt; - Performance Dashboard for PostgreSQL. See &lt;a href=&quot;https://github.com/ankane/pghero&quot;&gt;PgHero&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/X6ks6o&quot;&gt;Pundit&lt;/a&gt; - Authorization system. See &lt;a href=&quot;https://rubygems.org/gems/pundit&quot;&gt;Pundit&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/z5OsYq&quot;&gt;Vue with InertiaJS&lt;/a&gt; - Library supporting conventional interface between
front-end tools (React, Vue.js, and Svelte) and back-end (Laravel and Rails).
See &lt;a href=&quot;https://inertiajs.com/&quot;&gt;InertiaJs&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/x7msBK&quot;&gt;SendGrid&lt;/a&gt; - Configures Ruby support for &lt;a href=&quot;https://sendgrid.com/&quot;&gt;SendGrid&lt;/a&gt; email service API&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/VwysPq&quot;&gt;GraphQL&lt;/a&gt; - Add a GraphQL API to your Rails app&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/zmnsgN&quot;&gt;DelayedJob&lt;/a&gt; - Background Job processing. See &lt;a href=&quot;https://github.com/collectiveidea/delayed_job&quot;&gt;DelayedJob&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://railsbytes.com/public/templates/VAjsZ6&quot;&gt;Sidekiq&lt;/a&gt; - Background Job processing. See &lt;a href=&quot;https://github.com/mperham/sidekiq/&quot;&gt;Sidekiq&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
        <pubDate>Thu, 10 Dec 2020 10:38:55 -0500</pubDate>
        <link>https://www.rubycoloredglasses.com/2020/12/generating-a-new-rails-project/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2020/12/generating-a-new-rails-project/</guid>
        
        <category>api</category>
        
        <category>webpacker</category>
        
        <category>editorconfig</category>
        
        
        <category>rails</category>
        
        <category>vuejs</category>
        
      </item>
    
      <item>
        <title>How to Insert Special Entities in React</title>
        <description>&lt;h2 id=&quot;generating-characters&quot;&gt;Generating Characters&lt;/h2&gt;

&lt;p&gt;You can generate UTF-16 characters in ES6 using &lt;a href=&quot;https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCharCode&quot;&gt;String.fromCharCode()&lt;/a&gt;,
which takes one or more UTF-16 codes as input and returns the unicode
character(s) specified.&lt;/p&gt;

&lt;div class=&quot;language-javascript highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c1&quot;&gt;// hex code input&lt;/span&gt;
&lt;span class=&quot;kd&quot;&gt;let&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;copyright&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;fromCodePoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mh&quot;&gt;0x00A9&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;// &quot;©&quot;&lt;/span&gt;

&lt;span class=&quot;c1&quot;&gt;// decimal code input&lt;/span&gt;
&lt;span class=&quot;kd&quot;&gt;let&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;copyright&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;fromCodePoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;0169&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
&lt;span class=&quot;c1&quot;&gt;// &quot;©&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;!--more--&gt;

&lt;p&gt;Here is a list of the codes for common characters I’ve seen used in websites:&lt;/p&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Label&lt;/th&gt;
      &lt;th&gt;Character&lt;/th&gt;
      &lt;th&gt;Decimal&lt;/th&gt;
      &lt;th&gt;Hex&lt;/th&gt;
      &lt;th&gt;HTML&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;Copyright&lt;/td&gt;
      &lt;td&gt;©&lt;/td&gt;
      &lt;td&gt;169&lt;/td&gt;
      &lt;td&gt;0x000A9&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;copy;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Registered&lt;/td&gt;
      &lt;td&gt;®&lt;/td&gt;
      &lt;td&gt;174&lt;/td&gt;
      &lt;td&gt;0x000AE&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;reg;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Trademark&lt;/td&gt;
      &lt;td&gt;™&lt;/td&gt;
      &lt;td&gt;8482&lt;/td&gt;
      &lt;td&gt;0x02122&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;trade;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Euro&lt;/td&gt;
      &lt;td&gt;€&lt;/td&gt;
      &lt;td&gt;8364&lt;/td&gt;
      &lt;td&gt;0x020AC&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;euro;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Dollar&lt;/td&gt;
      &lt;td&gt;$&lt;/td&gt;
      &lt;td&gt;36&lt;/td&gt;
      &lt;td&gt;0x00024&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;dollar;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Ohm&lt;/td&gt;
      &lt;td&gt;Ω&lt;/td&gt;
      &lt;td&gt;8486&lt;/td&gt;
      &lt;td&gt;0x02126&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;ohm;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Degree&lt;/td&gt;
      &lt;td&gt;°&lt;/td&gt;
      &lt;td&gt;176&lt;/td&gt;
      &lt;td&gt;0x000B0&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;deg;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Micro&lt;/td&gt;
      &lt;td&gt;µ&lt;/td&gt;
      &lt;td&gt;181&lt;/td&gt;
      &lt;td&gt;0x000B5&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;micro;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Em Dash&lt;/td&gt;
      &lt;td&gt;—&lt;/td&gt;
      &lt;td&gt;8212&lt;/td&gt;
      &lt;td&gt;0x201&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;mdash;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Non Breaking Space&lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
      &lt;td&gt;160&lt;/td&gt;
      &lt;td&gt;0x000A0&lt;/td&gt;
      &lt;td&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;&amp;amp;nbsp;&lt;/code&gt;&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;p&gt;If you need a symbol not listed above, see the &lt;a href=&quot;https://dev.w3.org/html5/html-author/charref&quot;&gt;HTML5 Character Reference&lt;/a&gt;,
or the &lt;a href=&quot;https://en.wikipedia.org/wiki/List_of_Unicode_characters&quot;&gt;List of Unicode Characters&lt;/a&gt;.&lt;/p&gt;

&lt;h2 id=&quot;using-with-react-components&quot;&gt;Using with React Components&lt;/h2&gt;

&lt;p&gt;After generating the character as a constant, just insert it into your JSX as
needed.&lt;/p&gt;

&lt;div class=&quot;language-jsx highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;k&quot;&gt;import&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;React&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;from&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;react&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;

&lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;copyrightMessage&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;()&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&amp;gt;&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;

  &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;copyright&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;fromCodePoint&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mh&quot;&gt;0x00A9&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
  &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;year&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;2020&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
  &lt;span class=&quot;kd&quot;&gt;const&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;companyName&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;Company Name&lt;/span&gt;&lt;span class=&quot;dl&quot;&gt;&apos;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;

  &lt;span class=&quot;k&quot;&gt;return&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;span&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;&amp;gt;&lt;/span&gt;
     &lt;span class=&quot;si&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;`&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;copyright&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;year&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;${&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;companyName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;`&lt;/span&gt;&lt;span class=&quot;si&quot;&gt;}&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;span&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;&amp;gt;&lt;/span&gt;
  &lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;};&lt;/span&gt;

&lt;span class=&quot;k&quot;&gt;export&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;default&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;copyrightFooter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;See also &lt;a href=&quot;https://shripadk.github.io/react/docs/jsx-gotchas.html&quot;&gt;JSX Gotchas&lt;/a&gt; for more approaches.&lt;/p&gt;

</description>
        <pubDate>Wed, 09 Dec 2020 16:14:10 -0500</pubDate>
        <link>https://www.rubycoloredglasses.com/2020/12/html-special-entities-in-react/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2020/12/html-special-entities-in-react/</guid>
        
        <category>special entities</category>
        
        <category>es6</category>
        
        <category>react</category>
        
        
        <category>javascript</category>
        
      </item>
    
      <item>
        <title>A New Solution for Personal and Small Business Websites</title>
        <description>&lt;h2 id=&quot;static-website-beginnings&quot;&gt;Static Website Beginnings&lt;/h2&gt;

&lt;p&gt;I’ve maintained my own personal blog, and maintained websites for small
businesses, since 2000. I started building websites by manually coding the files
in HTML, and creating images I crafted in Photoshop. I’d update the website by
uploading the files to the web hosting server using FTP. I later expanded on
this by learning CSS and JavaScript. For the longest time I used
&lt;a href=&quot;https://en.wikipedia.org/wiki/Adobe_Dreamweaver&quot;&gt;Macromedia Dreamweaver&lt;/a&gt; (now owned by Adobe), because it was the closest thing
to a web-standard compliant WYSIWYG editor, with a text/code editor that
supported code coloring.&lt;!--more--&gt; In 2002 I multiplied the power I yielded in
developing functional websites by learning how to use server-side PHP coding
with the MySQL database. This was my humble beginning as a full-stack developer.&lt;/p&gt;

&lt;p&gt;For myself this was fine, but for small businesses their relationship with
their “webmaster” could easily become strained because being available to update
a clients website usually didn’t pay much. Many website maintainers might be
unresponsive for days or weeks before updating your website. Even communicating
the simple text changes you desired were difficult to convey via email to your
webmaster.&lt;/p&gt;

&lt;h2 id=&quot;my-romance-with-wordpress&quot;&gt;My Romance with Wordpress&lt;/h2&gt;

&lt;p&gt;I worked for a hosting company from 2004 - 2008 so that I could expand upon my
ability to create websites by understanding the web hosting servers that host
the websites. I pursued learning Linux system administration, which included
learning how to install and configure all related services manually from the
Linux command line. The WHM/cPanel system, which made management of a server
simpler via a web-based management interface, had just grown in popularity in
2004, and was expanding in use to power armies of website servers in data
centers around the world. The majority of websites hosted from these servers
were powered by PHP/MySQL.&lt;/p&gt;

&lt;p&gt;During this time many individuals and companies were adopting Content Management
Systems (CMS) to power their website, because they provided an “administration”
area that allowed them to edit the content on their webpages, or even create
new pages or blog posts, without needing to contact a website developer. These
systems were PHP/MySQL applications, so working with them was a no brainer.&lt;/p&gt;

&lt;p&gt;The one CMS that stuck out due to its ease of use was &lt;a href=&quot;https://wordpress.org/&quot;&gt;Wordpress&lt;/a&gt;. Even though
Wordpress was designed as a blog rather than a CMS, Wordpress can be configured
to support a website by configuring a custom page as the homepage, rather
than the blog index page it defaults to. Additionally the blog functionality can
be hidden from the public website by removing the blog index page from the
websites navigation menu altogether. This approach, combined with the hundreds
of plugins and themes made for Wordpress made it a perfect platform for any
personal or small business website. Really it could meet the needs of any
website short of complex custom web applications.&lt;/p&gt;

&lt;p&gt;The cost and hassle of designing and maintaining a website had been
eliminated. Someone is now able to setup and maintain a website themselves
without coding skills necessary what so ever. Today you can sign-up for
Wordpress hosting with companies such as &lt;a href=&quot;https://www.bluehost.com/wordpress&quot;&gt;BlueHost&lt;/a&gt; or &lt;a href=&quot;https://www.hostgator.com/managed-wordpress-hosting&quot;&gt;HostGator&lt;/a&gt;, purchase and
download a beautiful premium design/theme from a site such as &lt;a href=&quot;https://themeforest.net/category/wordpress&quot;&gt;ThemeForest&lt;/a&gt;, and
then upload and activate that theme in your Wordpress dashboard. Setting up the
pages and content for the website are all accessible to those with average
computer skills when using the &lt;a href=&quot;https://wordpress.com/support/dashboard/&quot;&gt;Wordpress administrative Dashboard&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I would tell everyone I knew that if they have a small business, Wordpress is
the best solution for their website, as opposed to limited template based
websites provided by platforms like Wix or SquareSpace. Wordpress has much more
flexibility and ability to expand in functionality as your business grows. You
can use free themes/plugins to begin, upgrade to premium themes/plugins later,
and if necessary you can even hire designers or developers to create completely
custom themes or plugins as needed.&lt;/p&gt;

&lt;p&gt;For a period of time I had my own cPanel web server running from a &lt;a href=&quot;https://en.wikipedia.org/wiki/Virtual_private_server&quot;&gt;Virtual
Private Server (VPS)&lt;/a&gt; hosted by &lt;a href=&quot;https://www.linode.com/&quot;&gt;Linode&lt;/a&gt;. I had created and hosted several
websites for small businesses and and friends hosted from this platform.&lt;/p&gt;

&lt;h2 id=&quot;the-pitfalls-of-wordpress&quot;&gt;The Pitfalls of Wordpress&lt;/h2&gt;

&lt;p&gt;I had tried to support these Wordpress sites by logging into their admin area
and updating the themes, plugins, and the Wordpress software itself when I
could. Everytime I did this I worried that I would unknowingly break the
functionality somewhere on these websites. Eventually down the line, this is
exactly what would happen.&lt;/p&gt;

&lt;p&gt;Updates to the Wordpress software, which are necessary to avoid security issues
with your website, often cause plugins and themes you are using to stop working
properly. The developers of Wordpress plugins and themes bare no guarantee that
they will provide updates so that your website continues to function properly.
Premium themes or plugins may offer some additional support and updates in the
future, but there is still no guarantee of this.&lt;/p&gt;

&lt;p&gt;I purchased an all-purpose theme builder framework called “Headway” for some of
the sites I maintained. It was not able to support upgrades or migrations to the
newer major versions of the framework theme they had released, so many sites
were stuck with the version they were using. Unexpectedly, “Headway” had longer
continued to be supported and maintained as of 2016. This was very frustrating
for the websites I had invested so much time into designing using their
framework.&lt;/p&gt;

&lt;p&gt;Often enough I would bare the responsible for helping to fix a website that had
become defaced by hackers, or contain mysterious scripting used to run phishing
scams. Sometimes hackers would try to send spam email from my server via a
hacked website, thus causing other website users to have issues sending email
from my server, because my server had been added to a spam blacklist as a result
of the spam activity.&lt;/p&gt;

&lt;p&gt;Just a note: Hosting your email from a cPanel service is not worth the hassle
either. I recommend using an email service such as &lt;a href=&quot;https://workspace.google.com/&quot;&gt;Google Workspace&lt;/a&gt;,
&lt;a href=&quot;https://www.fastmail.com/&quot;&gt;Fastmail&lt;/a&gt;, or &lt;a href=&quot;https://protonmail.com/&quot;&gt;ProtonMail&lt;/a&gt;.&lt;/p&gt;

&lt;h2 id=&quot;the-promise-of-jamstack&quot;&gt;The Promise of JAMstack&lt;/h2&gt;

&lt;p&gt;So what’s a better solution to setting up and maintaining a person or small
business website? JAMstack!&lt;/p&gt;

&lt;p&gt;Right now the this approach is only available to companies with budgets large
enough to hire custom website developers to implement, but I forsee this
becoming more acccessible to non-developers in the future.&lt;/p&gt;

&lt;p&gt;So what is this solution, and how is it better?&lt;/p&gt;

&lt;p&gt;The JAMstack recipe calls for using a static website generator to generate a
website that is powered by modern development tools such as &lt;a href=&quot;https://reactjs.org/&quot;&gt;ReactJS&lt;/a&gt; and
&lt;a href=&quot;https://graphql.org/&quot;&gt;GraphQL&lt;/a&gt;, that sources your content from a Headless Content Management System
(CMS). Static websites have no code running on the server side, so there is much
lower risk of your website being hacked. The only code is the JavaScript which
runs in the visitors web browser. Because your content is managed separately
by a Headless CMS, your content can be published not only to your website but
also to other platforms like mobile applications.&lt;/p&gt;

&lt;p&gt;The full JAMstack solution is made possible by using multiple components that
are provided as separate or integrated services. These include:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Headless CMS - Like Wordpress, this enables you to manage the text and images
that show up in your website in the form of pages, posts, or other types of
content.&lt;/li&gt;
  &lt;li&gt;Custom Website Code - Powered by a static website generator like &lt;a href=&quot;https://www.gatsbyjs.com/&quot;&gt;Gatsby&lt;/a&gt;;
provides your site design, sources your updated content from the Headless
CMS, to create your static website presentation.&lt;/li&gt;
  &lt;li&gt;Git repository host - Most people use &lt;a href=&quot;https://github.com/&quot;&gt;Github&lt;/a&gt;, &lt;a href=&quot;https://about.gitlab.com/&quot;&gt;Gitlab&lt;/a&gt;, or &lt;a href=&quot;https://bitbucket.org/&quot;&gt;BitBucket&lt;/a&gt; to
host their website code in a Git repository.&lt;/li&gt;
  &lt;li&gt;Build system - This system is triggered by updates to your website code,
or by updates to your content in the Headless CMS. This system might be a
continuous integration / continuous delivery (CI/CD) system, or simply
a script setup on your web server. When triggered it builds the updated
version of your website and deploys it to the public website.&lt;/li&gt;
  &lt;li&gt;Hosting - This can be a simple web server, a cluster of servers, or a content
delivery network (CDN).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Several Headless CMS services currently exist with free tier plans.
See &lt;a href=&quot;https://jamstack.org/headless-cms/&quot;&gt;JAMstack - Top Headless Content Management Systems&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So all you need to do if you’re a small business with the resources to hire a
developer is ask them to to integrate a website layout you choose from a premium
website design template market such as &lt;a href=&quot;https://themeforest.net/category/wordpress&quot;&gt;ThemeForest&lt;/a&gt; into a JAMstack codebase
powered by frameworks such as &lt;a href=&quot;https://www.gatsbyjs.com/&quot;&gt;Gatsby&lt;/a&gt; or one of the other &lt;a href=&quot;https://jamstack.org/generators/&quot;&gt;site generators&lt;/a&gt;,
and configure it to automatically regenerate and publish to your static hosting
provider each time you update or add any content to the Headless CMS.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://www.netlify.com/&quot;&gt;Netlify&lt;/a&gt; currently provides a CMS, build system, and CDN hosting with a free
tier plan to help you get started, with paid plans once your business needs
more. &lt;a href=&quot;https://render.com/&quot;&gt;Render&lt;/a&gt; also provides an integrated build service and hosting.&lt;/p&gt;

&lt;p&gt;Hopefully at some point in the future a flexible all-in-one solution will exist
that enables a business to create a website as quick and easy as Wordpress, but
powered by a flexible JAMstack infrastructure that you can override with your
own custom front-end once your business needs custom development work.&lt;/p&gt;

&lt;p&gt;It turns out that designers are starting to publish Gatsby themes already.&lt;/p&gt;

&lt;p&gt;There may be some themes on ThemeForest that support Gatsby, such as &lt;a href=&quot;https://themeforest.net/item/flexiblog-react-gatsby-blog-template/27538998&quot;&gt;Flexiblog&lt;/a&gt;
which supports the &lt;a href=&quot;https://www.contentful.com/&quot;&gt;Contentful&lt;/a&gt; or &lt;a href=&quot;https://www.sanity.io/&quot;&gt;Sanity&lt;/a&gt; CMS. If you really want to find a
design that supports this approach, I’d recommend checking out
&lt;a href=&quot;https://jamstackthemes.dev/&quot;&gt;JAMstack Themes&lt;/a&gt;.&lt;/p&gt;

</description>
        <pubDate>Sat, 05 Dec 2020 11:02:40 -0500</pubDate>
        <link>https://www.rubycoloredglasses.com/2020/12/jamstack-websites/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2020/12/jamstack-websites/</guid>
        
        <category>gatsby</category>
        
        <category>headlesscms</category>
        
        <category>render</category>
        
        <category>github-pages</category>
        
        
        <category>jamstack</category>
        
      </item>
    
      <item>
        <title>VueJS - Built-In &amp; Reserved Tags</title>
        <description>&lt;p&gt;I’m working on an app that is meant to present a list of “steps” along a certain
“path”. I tried to create a component called “path”, but this wasn’t allowed.&lt;/p&gt;

&lt;p&gt;I got this error in the console.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;vue.runtime.esm.js:638 &lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;Vue warn]: Do not use built-in or reserved HTML elements as component &lt;span class=&quot;nb&quot;&gt;id&lt;/span&gt;: path
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;!--more--&gt;
&lt;p&gt;It turns out that HTML and SVG tags are reserved and cannot be used as VueJS
component names.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href=&quot;https://github.com/vuejs/vue/blob/a59e05c2f/dist/vue.js#L134&quot;&gt;Built-In Tags&lt;/a&gt;
    &lt;ul&gt;
      &lt;li&gt;slot&lt;/li&gt;
      &lt;li&gt;component&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;&lt;a href=&quot;https://github.com/vuejs/vue/blob/a59e05c2f/dist/vue.js#L5614,L5616&quot;&gt;Reserved Tags&lt;/a&gt;
    &lt;ul&gt;
      &lt;li&gt;&lt;a href=&quot;https://github.com/vuejs/vue/blob/a59e05c2f/dist/vue.js#L5589,L5601&quot;&gt;HTML Tags&lt;/a&gt;
        &lt;ul&gt;
          &lt;li&gt;html&lt;/li&gt;
          &lt;li&gt;body&lt;/li&gt;
          &lt;li&gt;base&lt;/li&gt;
          &lt;li&gt;head&lt;/li&gt;
          &lt;li&gt;link&lt;/li&gt;
          &lt;li&gt;meta&lt;/li&gt;
          &lt;li&gt;style&lt;/li&gt;
          &lt;li&gt;title&lt;/li&gt;
          &lt;li&gt;address&lt;/li&gt;
          &lt;li&gt;article&lt;/li&gt;
          &lt;li&gt;aside&lt;/li&gt;
          &lt;li&gt;footer&lt;/li&gt;
          &lt;li&gt;header&lt;/li&gt;
          &lt;li&gt;h1&lt;/li&gt;
          &lt;li&gt;h2&lt;/li&gt;
          &lt;li&gt;h3&lt;/li&gt;
          &lt;li&gt;h4&lt;/li&gt;
          &lt;li&gt;h5&lt;/li&gt;
          &lt;li&gt;h6&lt;/li&gt;
          &lt;li&gt;hgroup&lt;/li&gt;
          &lt;li&gt;nav&lt;/li&gt;
          &lt;li&gt;section&lt;/li&gt;
          &lt;li&gt;div&lt;/li&gt;
          &lt;li&gt;dd&lt;/li&gt;
          &lt;li&gt;dl&lt;/li&gt;
          &lt;li&gt;dt&lt;/li&gt;
          &lt;li&gt;figcaption&lt;/li&gt;
          &lt;li&gt;figure&lt;/li&gt;
          &lt;li&gt;picture&lt;/li&gt;
          &lt;li&gt;hr&lt;/li&gt;
          &lt;li&gt;img&lt;/li&gt;
          &lt;li&gt;li&lt;/li&gt;
          &lt;li&gt;main&lt;/li&gt;
          &lt;li&gt;ol&lt;/li&gt;
          &lt;li&gt;p&lt;/li&gt;
          &lt;li&gt;pre&lt;/li&gt;
          &lt;li&gt;ul&lt;/li&gt;
          &lt;li&gt;a&lt;/li&gt;
          &lt;li&gt;b&lt;/li&gt;
          &lt;li&gt;abbr&lt;/li&gt;
          &lt;li&gt;bdi&lt;/li&gt;
          &lt;li&gt;bdo&lt;/li&gt;
          &lt;li&gt;br&lt;/li&gt;
          &lt;li&gt;cite&lt;/li&gt;
          &lt;li&gt;code&lt;/li&gt;
          &lt;li&gt;data&lt;/li&gt;
          &lt;li&gt;dfn&lt;/li&gt;
          &lt;li&gt;em&lt;/li&gt;
          &lt;li&gt;i&lt;/li&gt;
          &lt;li&gt;kbd&lt;/li&gt;
          &lt;li&gt;mark&lt;/li&gt;
          &lt;li&gt;q&lt;/li&gt;
          &lt;li&gt;rp&lt;/li&gt;
          &lt;li&gt;rt&lt;/li&gt;
          &lt;li&gt;rtc&lt;/li&gt;
          &lt;li&gt;ruby&lt;/li&gt;
          &lt;li&gt;s&lt;/li&gt;
          &lt;li&gt;samp&lt;/li&gt;
          &lt;li&gt;small&lt;/li&gt;
          &lt;li&gt;span&lt;/li&gt;
          &lt;li&gt;strong&lt;/li&gt;
          &lt;li&gt;sub&lt;/li&gt;
          &lt;li&gt;sup&lt;/li&gt;
          &lt;li&gt;time&lt;/li&gt;
          &lt;li&gt;u&lt;/li&gt;
          &lt;li&gt;var&lt;/li&gt;
          &lt;li&gt;wbr&lt;/li&gt;
          &lt;li&gt;area&lt;/li&gt;
          &lt;li&gt;audio&lt;/li&gt;
          &lt;li&gt;map&lt;/li&gt;
          &lt;li&gt;track&lt;/li&gt;
          &lt;li&gt;video&lt;/li&gt;
          &lt;li&gt;embed&lt;/li&gt;
          &lt;li&gt;object&lt;/li&gt;
          &lt;li&gt;param&lt;/li&gt;
          &lt;li&gt;source&lt;/li&gt;
          &lt;li&gt;canvas&lt;/li&gt;
          &lt;li&gt;script&lt;/li&gt;
          &lt;li&gt;noscript&lt;/li&gt;
          &lt;li&gt;del&lt;/li&gt;
          &lt;li&gt;ins&lt;/li&gt;
          &lt;li&gt;caption&lt;/li&gt;
          &lt;li&gt;col&lt;/li&gt;
          &lt;li&gt;colgroup&lt;/li&gt;
          &lt;li&gt;table&lt;/li&gt;
          &lt;li&gt;thead&lt;/li&gt;
          &lt;li&gt;tbody&lt;/li&gt;
          &lt;li&gt;td&lt;/li&gt;
          &lt;li&gt;th&lt;/li&gt;
          &lt;li&gt;tr&lt;/li&gt;
          &lt;li&gt;button&lt;/li&gt;
          &lt;li&gt;datalist&lt;/li&gt;
          &lt;li&gt;fieldset&lt;/li&gt;
          &lt;li&gt;form&lt;/li&gt;
          &lt;li&gt;input&lt;/li&gt;
          &lt;li&gt;label&lt;/li&gt;
          &lt;li&gt;legend&lt;/li&gt;
          &lt;li&gt;meter&lt;/li&gt;
          &lt;li&gt;optgroup&lt;/li&gt;
          &lt;li&gt;option&lt;/li&gt;
          &lt;li&gt;output&lt;/li&gt;
          &lt;li&gt;progress&lt;/li&gt;
          &lt;li&gt;select&lt;/li&gt;
          &lt;li&gt;textarea&lt;/li&gt;
          &lt;li&gt;details&lt;/li&gt;
          &lt;li&gt;dialog&lt;/li&gt;
          &lt;li&gt;menu&lt;/li&gt;
          &lt;li&gt;menuitem&lt;/li&gt;
          &lt;li&gt;summary&lt;/li&gt;
          &lt;li&gt;content&lt;/li&gt;
          &lt;li&gt;element&lt;/li&gt;
          &lt;li&gt;shadow&lt;/li&gt;
          &lt;li&gt;template&lt;/li&gt;
          &lt;li&gt;blockquote&lt;/li&gt;
          &lt;li&gt;iframe&lt;/li&gt;
          &lt;li&gt;tfoot&lt;/li&gt;
        &lt;/ul&gt;
      &lt;/li&gt;
      &lt;li&gt;&lt;a href=&quot;https://github.com/vuejs/vue/blob/a59e05c2f/dist/vue.js#L5603,L5610&quot;&gt;SVG Tags&lt;/a&gt;
        &lt;ul&gt;
          &lt;li&gt;svg&lt;/li&gt;
          &lt;li&gt;animate&lt;/li&gt;
          &lt;li&gt;circle&lt;/li&gt;
          &lt;li&gt;clippath&lt;/li&gt;
          &lt;li&gt;cursor&lt;/li&gt;
          &lt;li&gt;defs&lt;/li&gt;
          &lt;li&gt;desc&lt;/li&gt;
          &lt;li&gt;ellipse&lt;/li&gt;
          &lt;li&gt;filter&lt;/li&gt;
          &lt;li&gt;font-face&lt;/li&gt;
          &lt;li&gt;foreignObject&lt;/li&gt;
          &lt;li&gt;g&lt;/li&gt;
          &lt;li&gt;glyph&lt;/li&gt;
          &lt;li&gt;image&lt;/li&gt;
          &lt;li&gt;line&lt;/li&gt;
          &lt;li&gt;marker&lt;/li&gt;
          &lt;li&gt;mask&lt;/li&gt;
          &lt;li&gt;missing-glyph&lt;/li&gt;
          &lt;li&gt;path&lt;/li&gt;
          &lt;li&gt;pattern&lt;/li&gt;
          &lt;li&gt;polygon&lt;/li&gt;
          &lt;li&gt;polyline&lt;/li&gt;
          &lt;li&gt;rect&lt;/li&gt;
          &lt;li&gt;switch&lt;/li&gt;
          &lt;li&gt;symbol&lt;/li&gt;
          &lt;li&gt;text&lt;/li&gt;
          &lt;li&gt;textpath&lt;/li&gt;
          &lt;li&gt;tspan&lt;/li&gt;
          &lt;li&gt;use&lt;/li&gt;
          &lt;li&gt;view&lt;/li&gt;
        &lt;/ul&gt;
      &lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;
</description>
        <pubDate>Sat, 28 Mar 2020 18:42:00 -0400</pubDate>
        <link>https://www.rubycoloredglasses.com/2020/03/vuejs-reserved-tags/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2020/03/vuejs-reserved-tags/</guid>
        
        <category>vue</category>
        
        
        <category>vue</category>
        
      </item>
    
      <item>
        <title>Updating Vue-Loader to v15 with Webpacker</title>
        <description>&lt;p&gt;I recently decided to jump into working with &lt;a href=&quot;https://vuejs.org/&quot;&gt;VueJS&lt;/a&gt; again within the context
of a project I’m working on that uses Rails 5 with Webpacker.&lt;/p&gt;

&lt;p&gt;I upgraded Webpacker from v3.6 to v4.2.2, Vue from v2.5.16 to v2.6.11,
and Vue-Loader from v14.2.2 to v15.9.0.&lt;/p&gt;

&lt;p&gt;After making this update I got the following error:&lt;/p&gt;

&lt;!--more--&gt;

&lt;div class=&quot;language-javascript highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;nx&quot;&gt;ERROR&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;app&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;javascript&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;my_pack&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;components&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;App&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;vue&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;Module&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;Error&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;k&quot;&gt;from&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;node_modules&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;vue&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;loader&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;lib&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;index&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;js&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;):&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;vue&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;loader&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;was&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;used&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;without&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;the&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;corresponding&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;plugin&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;Make&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;sure&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;to&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;include&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;VueLoaderPlugin&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;your&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;webpack&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;
&lt;span class=&quot;nb&quot;&gt;Error&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;vue&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;loader&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;was&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;used&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;without&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;the&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;corresponding&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;plugin&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;Make&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;sure&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;to&lt;/span&gt;
&lt;span class=&quot;nx&quot;&gt;include&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;VueLoaderPlugin&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;in&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;your&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;webpack&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;config&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;at&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;Object&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;module&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;exports&lt;/span&gt;
&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;sr&quot;&gt;/Users/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;jason&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Projects&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;my_app&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;node_modules&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;vue&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;loader&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;lib&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;index&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;js&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;36&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;29&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;I was able to identify that I needed to make some configuration changes after
&lt;a href=&quot;https://vue-loader.vuejs.org/migrating.html#a-plugin-is-now-required&quot;&gt;updatiing Vue-Loader from v14 to v15&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I’m a bit rusty on how to navigate the Node/JS eco-system, and the documentation
on Webpack doesn’t apply to the Rails method of configuring the app with
Webpacker.&lt;/p&gt;

&lt;p&gt;I recall that after I first setup this Rails app to use Vue with Webpacker that
I had to use the following rake task to configure it to use Vue:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;bundle &lt;span class=&quot;nb&quot;&gt;exec &lt;/span&gt;rails webpacker:install:vue
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;I wasn’t able to resolve this error until I applied &lt;a href=&quot;https://github.com/rails/webpacker/blob/cb4e4c8c/lib/install/vue.rb#L7,L13&quot;&gt;these modifications&lt;/a&gt; to
&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;config/webpack/environment.js&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;I didn’t want to miss any other updates to the boilerplate configuration,
nor do I want my own modifications overwritten. So what I recommend you do
to upgrade is to make any commits in Git before re-running the above rake
task again. Here’s what I got from the output:&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;nv&quot;&gt;$ &lt;/span&gt;bundle &lt;span class=&quot;nb&quot;&gt;exec &lt;/span&gt;rails webpacker:install:vue
Copying vue loader to config/webpack/loaders
    conflict  config/webpack/loaders/vue.js
Overwrite /Users/jason/Projects/seed/config/webpack/loaders/vue.js? &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;enter &lt;span class=&quot;s2&quot;&gt;&quot;h&quot;&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;for &lt;/span&gt;&lt;span class=&quot;nb&quot;&gt;help&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;Ynaqdhm] Y
       force  config/webpack/loaders/vue.js
Adding vue loader plugin to config/webpack/environment.js
      insert  config/webpack/environment.js
      insert  config/webpack/environment.js
Adding vue loader to config/webpack/environment.js
      insert  config/webpack/environment.js
      insert  config/webpack/environment.js
Updating webpack paths to include .vue file extension
File unchanged! The supplied flag value not found!  config/webpacker.yml
Copying the example entry file to /Users/jason/Projects/seed/app/javascript/packs
      create  app/javascript/packs/hello_vue.js
Copying Vue app file to /Users/jason/Projects/seed/app/javascript/packs
      create  app/javascript/app.vue
Installing all Vue dependencies
         run  yarn add vue vue-loader vue-template-compiler from &lt;span class=&quot;s2&quot;&gt;&quot;.&quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Expect that it will duplicate certain modifications it makes, but if you use
&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git diff&lt;/code&gt; on the modified files afterwards you can surely detect these and fix
them.&lt;/p&gt;

&lt;div class=&quot;language-bash highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;nv&quot;&gt;$ &lt;/span&gt;git diff config/webpack/environment.js
diff &lt;span class=&quot;nt&quot;&gt;--git&lt;/span&gt; a/config/webpack/environment.js b/config/webpack/environment.js
index 08d2baf..0f3a57d 100644
&lt;span class=&quot;nt&quot;&gt;---&lt;/span&gt; a/config/webpack/environment.js
+++ b/config/webpack/environment.js
@@ &lt;span class=&quot;nt&quot;&gt;-1&lt;/span&gt;,8 +1,12 @@
 const &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt; environment &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; require&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;@rails/webpacker&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
 const &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt; VueLoaderPlugin &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; require&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;vue-loader&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
 const vue &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; require&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;./loaders/vue&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
+const &lt;span class=&quot;o&quot;&gt;{&lt;/span&gt; VueLoaderPlugin &lt;span class=&quot;o&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; require&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;vue-loader&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
+const vue &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; require&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;./loaders/vue&quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;

 environment.loaders.append&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;vue&quot;&lt;/span&gt;, vue&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
 environment.plugins.prepend&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;VueLoaderPlugin&quot;&lt;/span&gt;, new VueLoaderPlugin&lt;span class=&quot;o&quot;&gt;())&lt;/span&gt;

+environment.plugins.prepend&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;VueLoaderPlugin&quot;&lt;/span&gt;, new VueLoaderPlugin&lt;span class=&quot;o&quot;&gt;())&lt;/span&gt;
+environment.loaders.prepend&lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;vue&quot;&lt;/span&gt;, vue&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
 module.exports &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; environment
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;I already manually added ‘.vue’ under ‘extensions’ in the config/webpacker.yml
file. I deleted &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;app/javascript/app.vue&lt;/code&gt; and &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;app/javascript/packs/hello_vue.js&lt;/code&gt;
because I don’t need them. Now I’m no longer getting the error from
&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;./bin/webpack-dev-server&lt;/code&gt;.&lt;/p&gt;

</description>
        <pubDate>Sun, 01 Mar 2020 14:37:00 -0500</pubDate>
        <link>https://www.rubycoloredglasses.com/2020/03/vue-loader-webpacker/</link>
        <guid isPermaLink="true">https://www.rubycoloredglasses.com/2020/03/vue-loader-webpacker/</guid>
        
        <category>webpacker</category>
        
        <category>rails</category>
        
        <category>vue</category>
        
        <category>vue-loader</category>
        
        
        <category>rails</category>
        
      </item>
    
  </channel>
</rss>
