<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Interaction Designs</title>
    <description>The latest articles on DEV Community by Interaction Designs (@mwagner24).</description>
    <link>https://dev.to/mwagner24</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F566767%2F7a3dc8d2-2863-463b-bb0f-a86ea7569223.png</url>
      <title>DEV Community: Interaction Designs</title>
      <link>https://dev.to/mwagner24</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mwagner24"/>
    <language>en</language>
    <item>
      <title>Creating a Blog with 11ty and 11ty Templates</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Thu, 21 Apr 2022 18:43:19 +0000</pubDate>
      <link>https://dev.to/mwagner24/creating-a-blog-with-11ty-and-hax11ty-bie</link>
      <guid>https://dev.to/mwagner24/creating-a-blog-with-11ty-and-hax11ty-bie</guid>
      <description>&lt;h2&gt;
  
  
  There's levels to 11ty
&lt;/h2&gt;

&lt;h3&gt;
  
  
  11ty Hello-World Blog
&lt;/h3&gt;

&lt;p&gt;The first example of 11ty we'll look at is a simple hello-world style blog.&lt;br&gt;
We'll use the &lt;a href="https://www.11ty.dev/" rel="noopener noreferrer"&gt;documentation&lt;/a&gt; to start a project with 11ty. Following these instructions, we install the necessary packages to our project to be able to run in 11ty.&lt;/p&gt;

&lt;p&gt;Plug-ins are very useful with 11ty but they are not needed. In this example, I used a &lt;a href="https://www.11ty.dev/docs/plugins/syntaxhighlight/" rel="noopener noreferrer"&gt;syntax highlighter plug-in&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Once these steps are done you're all set up and ready to create your site in markdown. &lt;/p&gt;

&lt;p&gt;The simple blog I made looks like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8yr0dvj9vtpfynb1fkj6.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8yr0dvj9vtpfynb1fkj6.JPG" alt="11ty blog site"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you'd like to see the code for the site check out my simple example on &lt;a href="https://github.com/mwagnerPSU/11ty-blog" rel="noopener noreferrer"&gt;Github&lt;/a&gt;, all the site content is held in the README.md file.&lt;/p&gt;

&lt;h3&gt;
  
  
  11ty Blog with Template
&lt;/h3&gt;

&lt;p&gt;The next example we'll look at goes more into depth of 11ty. We are creating this site from this &lt;a href="https://github.com/11ty/eleventy-base-blog" rel="noopener noreferrer"&gt;template&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;This site works by making a collection of markdown files that hold each post and get displayed by linking to those files in the index.html.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqv16e2t3w3np6t2b3a2w.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqv16e2t3w3np6t2b3a2w.JPG" alt="posts folder"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffx3mdvuanugkwcpip4iz.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffx3mdvuanugkwcpip4iz.JPG" alt="post linking code"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here we are able to link on any page, the location of another file.&lt;/p&gt;

&lt;p&gt;Each post follows a similar format (title, description, date, tags, layout, post content):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhprlof4dwg74636u6i4w.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhprlof4dwg74636u6i4w.JPG" alt="post format"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you'd like to see the code for this 11ty blog, check out my &lt;a href="https://github.com/mwagnerPSU/11ty-blog-with-template" rel="noopener noreferrer"&gt;Github&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Google 11ty Blog
&lt;/h3&gt;

&lt;p&gt;Lastly, we'll look at a template created by Google that uses 11ty to make a blog. If you'd like to check out the template yourself, this is their &lt;a href="https://github.com/google/eleventy-high-performance-blog" rel="noopener noreferrer"&gt;Github&lt;/a&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  Similarities
&lt;/h4&gt;

&lt;p&gt;Google's 11ty template is structured almost exactly like the pervious blog template we looked at. All of the posts are held in one folder and each post has a bit of metadata linked with it then room for the post content.&lt;/p&gt;

&lt;h4&gt;
  
  
  Differences
&lt;/h4&gt;

&lt;p&gt;The biggest difference you'll notice is the Google template is a lot more esthetically pleasing than the previous 11ty template. On this template there is also a way to make a draft post. By adding &lt;code&gt;draft: true&lt;/code&gt; in the metadata of the post it will hide that post from the production site and only view it in your developer mode.&lt;/p&gt;

&lt;h4&gt;
  
  
  Why is this template worth using?
&lt;/h4&gt;

&lt;p&gt;Google created this template to have the highest performance, accessibility, best practices, and SEO possible (which is very important since this is how Google rates if your site is put high on the engine's search page). With their template you will be able to take full advantage of Google's search algorithm.&lt;/p&gt;

&lt;p&gt;I made a quick sample blog that can be found on my &lt;a href="https://github.com/mwagnerPSU/eleventy-high-performance-blog" rel="noopener noreferrer"&gt;Github&lt;/a&gt; and looks surprisingly well for not doing any additional formatting or additional styling.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2u68m1kwd61i1o2i9nk6.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2u68m1kwd61i1o2i9nk6.JPG" alt="google template 11ty blog"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>programming</category>
      <category>markdown</category>
    </item>
    <item>
      <title>New to Docker? Try it out for free!</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Wed, 20 Apr 2022 17:26:43 +0000</pubDate>
      <link>https://dev.to/mwagner24/new-to-docker-try-it-out-for-free-dbe</link>
      <guid>https://dev.to/mwagner24/new-to-docker-try-it-out-for-free-dbe</guid>
      <description>&lt;p&gt;Docker is a powerful tool used to for containerization of microservices. This provides a quick way to spin up sections of an application or website that are needed at the time and spin them down after their function is served. This process saves server space, money, and makes it easier for pushing updates and fixes to a part of the project without breaking the whole thing.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Good and Bad
&lt;/h3&gt;

&lt;p&gt;Downside... the full power of Docker costs money. But you are able to use a free virtual server on &lt;a href="https://labs.play-with-docker.com/" rel="noopener noreferrer"&gt;Play with Docker&lt;/a&gt; to sharpen your skills, test out projects or just learn how it all works.&lt;/p&gt;

&lt;h3&gt;
  
  
  Try it Out
&lt;/h3&gt;

&lt;p&gt;If you click the link above, you'll be brought to Docker's free service where you get the full experience of Docker for 4 hours at a time.&lt;/p&gt;

&lt;p&gt;I'm going to show deploying a project on Github named &lt;a href="https://github.com/elmsln/HAXcms" rel="noopener noreferrer"&gt;HAXcms&lt;/a&gt;. HAXcms is a next-gen content management system fully built out of the open source project HAX (Headless Authoring eXperience).&lt;/p&gt;

&lt;h4&gt;
  
  
  Steps
&lt;/h4&gt;

&lt;ol&gt;
&lt;li&gt;Click the "Login" button on Play with Docker's homepage, and either login or create a new account (don't worry it's free).  Once you're logged in, hit the "Start" button and you will be brought to a page that looks like this:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft5sgkkzl5xegax8nhtn7.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft5sgkkzl5xegax8nhtn7.JPG" alt="play with docker homepage"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;From here you want to click the "+Add New Instance" button, which will spin up a virtual server for you to run your project on.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Now since we've started an instance we can begin running commands to build and run our project. Start by cloning the HAXcms project into your instance by clicking in the black box, typing &lt;code&gt;git clone https://github.com/elmsln/HAXcms.git&lt;/code&gt;, then hit 'Enter'.&lt;br&gt;
You'll see the progress of the project being cloned into your environment.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Once it's done cloning, let's navigate to that folder with &lt;code&gt;cd HAXcms&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Now we're going to build an image of the project. We do this by running &lt;code&gt;docker build . -t haxcms&lt;/code&gt;. &lt;code&gt;docker build&lt;/code&gt; is our command to run the build, &lt;code&gt;.&lt;/code&gt; selects the files in our project and &lt;code&gt;-t haxcms&lt;/code&gt; declares the name of the image we're making.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Once your image is built, we're ready to run the project in our container! Run &lt;code&gt;docker run -dp 80:80 haxcms&lt;/code&gt; and you'll notice a blue "80" link shows up next to the "Open Port" button.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fip3tqs9k7a0bucwk83tp.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fip3tqs9k7a0bucwk83tp.JPG" alt="docker running"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Click that link and a new tab will open with the running project on your computer.&lt;/p&gt;

&lt;h3&gt;
  
  
  You're all set!
&lt;/h3&gt;

&lt;p&gt;That's the basics to getting a project running with Play with Docker. If you'd like to run your own project or another project you've found, you can follow the same steps and replace the HAXcms areas with any project you'd like.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>programming</category>
      <category>microservices</category>
    </item>
    <item>
      <title>Deploy your next site using Vercel</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Tue, 19 Apr 2022 12:43:52 +0000</pubDate>
      <link>https://dev.to/mwagner24/deploy-your-next-site-using-vercel-17be</link>
      <guid>https://dev.to/mwagner24/deploy-your-next-site-using-vercel-17be</guid>
      <description>&lt;h2&gt;
  
  
  What is Vercel?
&lt;/h2&gt;

&lt;p&gt;Vercel is a "Function as a Service" platform to allow anyone to build, launch, and maintain any site for... free! Although there are paid models all the functionality to get a site up and running is completely free and relatively simple to use.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why is there a web components tag on this post?
&lt;/h2&gt;

&lt;p&gt;Currently, to deploy a site testing out web components you need what feels like an entire infrastructure behind it just to see if a simple button is working the right way.&lt;br&gt;
Now with Vercel's deployment, web components has never been easier!&lt;/p&gt;

&lt;h2&gt;
  
  
  Getting Started
&lt;/h2&gt;

&lt;p&gt;First, create a &lt;a href="https://vercel.com/dashboard"&gt;Vercel&lt;/a&gt; account. I'd recommend creating the account with the Github option, so your Vercel account is linked to your repositories. I would also recommend only sharing projects you want to deploy with your Vercel account so that Vercel does not try to deploy with other repos.&lt;/p&gt;

&lt;h3&gt;
  
  
  How to Deploy
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Importing the Project
&lt;/h4&gt;

&lt;p&gt;There are two main ways to deploy your site with Vercel; using the Vercel CLI or through Github.&lt;/p&gt;

&lt;p&gt;I'm going to explain the Github route since I personally think it is the best way to link your projects and keep them updated in Vercel.&lt;/p&gt;

&lt;p&gt;All of the docs for alternative routes can be found on Vercel's &lt;a href="https://vercel.com/docs/concepts/deployments/overview#vercel-cli"&gt;documentation&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Now that you've linked your Github account to Vercel you will see a dashboard much like this without any existing projects.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--N1Yzi1Wq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p1rvm1ruoqypd5bv2wc2.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--N1Yzi1Wq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p1rvm1ruoqypd5bv2wc2.JPG" alt="vercel dashboard" width="880" height="596"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here you can click "New Project" and select the Github repository you want to deploy. If you've turned on the selective repo sharing, you will need to&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Select "Add Github Account" in the drop down&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--4zBju5yQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lwv5k63m9gv6h38ae4ap.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--4zBju5yQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lwv5k63m9gv6h38ae4ap.png" alt="vercel github link" width="472" height="525"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Choose your Github account&lt;/li&gt;
&lt;li&gt;Scroll down to "Repository Access" and choose the repo you want to share&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kjG96eea--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mdmgtodhjvjqj7mvnoe2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kjG96eea--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mdmgtodhjvjqj7mvnoe2.png" alt="repository access" width="580" height="557"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Hit the "Save" button&lt;/li&gt;
&lt;li&gt;Hit the "Import" button on that project&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Configuring
&lt;/h4&gt;

&lt;p&gt;The best part of Vercel is most deployment configuration is done for you. The main three areas you need to edit next are "Root Directory", "Build and Output Settings", and "Environment Variables". Other than that... you're done.&lt;/p&gt;

&lt;p&gt;To deploy a project with web components, you will need a rollup-config file along with a build command that runs that file.&lt;/p&gt;

&lt;p&gt;If you need help with that configuration, check out the files in one of my Github &lt;a href="https://github.com/mwagnerPSU/sorting-question"&gt;repos&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Deployed!
&lt;/h3&gt;

&lt;p&gt;That's it! Hit the big "Deploy" button and watch your project come to life on a free site that is constantly updated with each push to your repo's main branch. There is no other updates needed on your side as Vercel will automatically rebuild your site with each new pull request.&lt;/p&gt;

</description>
      <category>webcomponents</category>
      <category>webdev</category>
      <category>programming</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Getting Started with Docker Desktop</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Tue, 12 Apr 2022 20:40:29 +0000</pubDate>
      <link>https://dev.to/mwagner24/getting-started-with-docker-desktop-5chj</link>
      <guid>https://dev.to/mwagner24/getting-started-with-docker-desktop-5chj</guid>
      <description>&lt;h3&gt;
  
  
  What is Docker?
&lt;/h3&gt;

&lt;p&gt;Docker is a platform used to ship microservices in small containers that most likely hold tiny pieces of an entire application. Docker allows for each microservice container to be ran and closed based on its current usage.&lt;/p&gt;

&lt;h3&gt;
  
  
  How do we use it?
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Setup
&lt;/h4&gt;

&lt;p&gt;We'll be looking at Docker Desktop to set up our containers but there is also a free web version on Docker's &lt;a href="https://labs.play-with-docker.com/" rel="noopener noreferrer"&gt;website&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If you do not already have Docker Desktop and you want to install it, you can follow the tutorial on Docker's &lt;a href="https://docs.docker.com/desktop/windows/install/" rel="noopener noreferrer"&gt;site&lt;/a&gt;. If you already have it installed or are using the online 'Play with Docker' feel free to follow along on your own machine.&lt;/p&gt;

&lt;h4&gt;
  
  
  Steps
&lt;/h4&gt;

&lt;h5&gt;
  
  
  DockerFile
&lt;/h5&gt;

&lt;p&gt;The first step is to have a program that we want to ship to Docker. For this example, I'm using a simple to-do app found on github &lt;a href="https://github.com/heyMP/ist402-docker/tree/master/labs/5-nodejs-todo-app" rel="noopener noreferrer"&gt;here&lt;/a&gt;. If you look through the files on this to-do app, you'll find a 'DockerFile'. This file is needed to be able to ship anything to Docker, this is what tells Docker what to do with your files. &lt;/p&gt;

&lt;p&gt;In this to-do app we have a few lines in our DockerFile:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;FROM node:10-alpine
WORKDIR /app
COPY . .
RUN yarn install --production
CMD ["node", "/app/src/index.js"]
EXPOSE 3000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These lines define our Docker container configuration and it runs a few commands in our container. &lt;code&gt;COPY . .&lt;/code&gt; gets our code in the container then the &lt;code&gt;RUN&lt;/code&gt; line installs all of our dependencies needed for the app, &lt;code&gt;CMD&lt;/code&gt; runs a few more needed commands for this app and finally &lt;code&gt;EXPOSE&lt;/code&gt; declares the port we want to run the container on.&lt;/p&gt;

&lt;h5&gt;
  
  
  Build
&lt;/h5&gt;

&lt;p&gt;Next, we want to build an image of our application. We'll build this by using our command line. We can navigate to the to-do app folder, '5-nodejs-todo-app', in our command prompt and run the command:&lt;br&gt;
&lt;code&gt;docker build -t [appName]&lt;/code&gt;.&lt;br&gt;
&lt;code&gt;docker build&lt;/code&gt; is what initiates the building of our image. &lt;code&gt;-t&lt;/code&gt; indicates the name of the image will come next in the command. &lt;code&gt;[appName]&lt;/code&gt; stands for the place where you insert whatever name you want (usually relating to what the image is).&lt;br&gt;
For this example, I used &lt;code&gt;docker build -t todoapp&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;If you are using Docker Desktop you'll see a new image appear under the 'Images' tab.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7bgvboqj6dh2oc2cvlhv.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7bgvboqj6dh2oc2cvlhv.png" alt="Docker Images"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h5&gt;
  
  
  Run
&lt;/h5&gt;

&lt;p&gt;Finally, we can run our application with Docker. Once the image is built, there are two ways we can create and run a container based on that image. The first we'll look at is in the command prompt. We can run our container by writing the command:&lt;br&gt;
&lt;code&gt;docker container run --name [nameForContainer] -p [hostPort]:[containerPort] -d [image ID]&lt;/code&gt;&lt;br&gt;
&lt;code&gt;docker container run&lt;/code&gt; is the command to begin and run our container. &lt;code&gt;--name&lt;/code&gt; says the name of the container we are making is coming next. &lt;code&gt;[nameForContainer]&lt;/code&gt; can be any name that describes the container you are currently making (I used todoapp again). &lt;code&gt;-p&lt;/code&gt; defines the ports we went to use. &lt;code&gt;[hostPort]&lt;/code&gt; is the port you want to open on your machine to run the Docker container. &lt;code&gt;[conatinerPort]&lt;/code&gt; is the port in the container you're making that links to the open port on your computer. &lt;code&gt;-d&lt;/code&gt; says the container should run detached from the command prompt we are in (this is because I'd like to see the feedback in the Docker Desktop rather than the command prompt). &lt;code&gt;[image ID]&lt;/code&gt; is where we place the ID of the image we made in the previous command. This ID can be found on Docker Desktop under the images tab, named 'Image ID'.&lt;/p&gt;

&lt;p&gt;The full command I used is:&lt;br&gt;
&lt;code&gt;docker container run --name todoapp -p 3000:3000 -d e02b378878b0&lt;/code&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  You're All Set!
&lt;/h3&gt;

&lt;p&gt;Head to &lt;code&gt;localhost:3000&lt;/code&gt; in your browser and you should see your To-Do app running!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpgojwulkcyjq8lwelxj5.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpgojwulkcyjq8lwelxj5.JPG" alt="Todo App"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>docker</category>
      <category>microservices</category>
      <category>programming</category>
    </item>
    <item>
      <title>Leveraging APIs for Microservices</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Tue, 01 Feb 2022 02:43:13 +0000</pubDate>
      <link>https://dev.to/mwagner24/leveraging-apis-for-microservices-2p4o</link>
      <guid>https://dev.to/mwagner24/leveraging-apis-for-microservices-2p4o</guid>
      <description>&lt;p&gt;The main idea of what were going to look at is using an IP locator API to define a location and display that location on google maps (internally and externally) and wire that location to a different, existing component.&lt;/p&gt;

&lt;h3&gt;
  
  
  API Calls
&lt;/h3&gt;

&lt;p&gt;Calling an API and receiving/storing its data is actually pretty simple as long as the API is designed correctly. In this case, we're going to look at an API called &lt;a href="https://freegeoip.app/"&gt;free GIO IP&lt;/a&gt;. Here we are able to get the general location (country, state, city, longitude, latitude) of an IP address. &lt;/p&gt;

&lt;p&gt;To make the call we are going to use a &lt;code&gt;fetch&lt;/code&gt; function that will access a link we pass into it and return the JSON data that is received from that link.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--nW2WIwcn--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/skogvxelwvbpq37zxa2h.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--nW2WIwcn--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/skogvxelwvbpq37zxa2h.JPG" alt="fetch example" width="341" height="240"&gt;&lt;/a&gt;&lt;br&gt;
In the code above we first start &lt;code&gt;fetch&lt;/code&gt; and pass our link that looks like this &lt;code&gt;https://freegeoip.app/json/[ip address]&lt;/code&gt;. &lt;code&gt;Fetch&lt;/code&gt; then returns a response of the data grabbed from the API associated with the IP we passed in. The &lt;code&gt;.then&lt;/code&gt; section is where we can go through that response and store the data in our program. Here, we are taking the longitude, latitude, city, and state and saving them to our existing properties.&lt;/p&gt;
&lt;h3&gt;
  
  
  Displaying our Data with Google Maps
&lt;/h3&gt;
&lt;h4&gt;
  
  
  Internally
&lt;/h4&gt;

&lt;p&gt;First, we're going to look at embedding a Google Map into our program using an &lt;code&gt;&amp;lt;iframe&amp;gt;&lt;/code&gt;. Since we have the longitude and latitude (found earlier ^) of the location we want to display, we can use those in our &lt;code&gt;iframe&lt;/code&gt; to embed the map.&lt;/p&gt;

&lt;p&gt;That may have sounded difficult and hard to implement but it really comes down to two lines of code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const url = `https://maps.google.com/maps?q=${this.lat},${this.long}&amp;amp;t=&amp;amp;z=15&amp;amp;ie=UTF8&amp;amp;iwloc=&amp;amp;output=embed`;
&amp;lt;iframe title="Where you are" src="${url}"&amp;gt;&amp;lt;/iframe&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our &lt;code&gt;url&lt;/code&gt; holds the link to google's mapping api and right after the &lt;code&gt;/maps?q=&lt;/code&gt; in the link, we place in the latitude and longitude we have already found. Then, all we have left is to place that url into the &lt;code&gt;src&lt;/code&gt; of our &lt;code&gt;&amp;lt;iframe&amp;gt;&lt;/code&gt; and the map will display, embedded in our page.&lt;/p&gt;

&lt;p&gt;For more info on using the Google Maps Platform check out their &lt;a href="https://developers.google.com/maps"&gt;developer page&lt;/a&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  Externally
&lt;/h4&gt;

&lt;p&gt;To create a link in our page that takes up to Google Maps with our desired location already in the view window is not too different from before. We can create a simple &lt;code&gt;&amp;lt;a&amp;gt;&lt;/code&gt; tag and place the link for an external path with our long and lat we've received before.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;a href="https://www.google.com/maps/@${this.lat},${this.long},14z"&amp;gt;
    See on Google
&amp;lt;/a&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here we've created a link that leads to google map's site with our long and lat coordinates and a zoom of 14 (&lt;code&gt;,14z&lt;/code&gt;). &lt;/p&gt;

&lt;h3&gt;
  
  
  Wiring with an Existing Component
&lt;/h3&gt;

&lt;p&gt;Let's say you want to use the data we received to utilize a different web component.&lt;/p&gt;

&lt;p&gt;For this example, we'll look at a tag named &lt;code&gt;&amp;lt;wikipedia -query&amp;gt;&lt;/code&gt; that will perform a wikipedia search and embed the page found into our site.&lt;br&gt;
Wikipedia-query info: &lt;a href="https://github.com/elmsln/lrnwebcomponents"&gt;Github&lt;/a&gt; &lt;a href="https://www.npmjs.com/package/@lrnwebcomponents/wikipedia-query"&gt;npmjs&lt;/a&gt;&lt;/p&gt;
&lt;h4&gt;
  
  
  Set Up
&lt;/h4&gt;

&lt;p&gt;We'll start by wiring the component into our program so we can implement the project. First, adding the package location to our &lt;code&gt;dependencies&lt;/code&gt; in &lt;code&gt;package.json&lt;/code&gt;.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--M9Wq1qjC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/smv1jgolq5mftnl3el5e.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--M9Wq1qjC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/smv1jgolq5mftnl3el5e.png" alt="dependencies example" width="320" height="71"&gt;&lt;/a&gt;&lt;br&gt;
Then we'll run an &lt;code&gt;npm install&lt;/code&gt; on our project to get all the needed assets to run &lt;code&gt;wikipedia-query&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Once the install is finished, we want to add a "bare import" to our program file to be able to access the tag we just installed. A "bare import" is a convention where we let LitElement find what exact file we are looking for rather than specifically declaring one. This is important for improving the maintainability of our code since file locations and structures can change over time.&lt;/p&gt;

&lt;p&gt;In this example, our "bare import" will look like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import '@lrnwebcomponents/wikipedia-query';
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Notice we only specify the general area of what we are importing and not a specific file name.&lt;/p&gt;

&lt;h4&gt;
  
  
  Utilization
&lt;/h4&gt;

&lt;p&gt;Now that we're all set up, we can do objectively the easiest part. Remember we want to use the &lt;code&gt;&amp;lt;wikipedia-query&amp;gt;&lt;/code&gt; tag to display a wiki page of the location we received from our API earlier. &lt;/p&gt;

&lt;p&gt;To implement our &lt;code&gt;&amp;lt;wikipedia-query&amp;gt;&lt;/code&gt; tag we pass our location into it's &lt;code&gt;search&lt;/code&gt; property and let the tag do the rest of the work for us.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;//finding wiki based on city and state
&amp;lt;wikipedia-query search="${this.city}, ${this.state}"&amp;gt;&amp;lt;/wikipedia-query&amp;gt;

//finding wiki based on city
&amp;lt;wikipedia-query search="${this.city}"&amp;gt;&amp;lt;/wikipedia-query&amp;gt;

//finding wiki based on state
&amp;lt;wikipedia-query search="${this.state}"&amp;gt;&amp;lt;/wikipedia-query&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Wrap It Up
&lt;/h3&gt;

&lt;p&gt;The main point in this post is the effectiveness of the &lt;code&gt;fetch&lt;/code&gt; function. We are able to set a call to any API, receive the JSON data, and use that data in any way we want.&lt;/p&gt;

&lt;p&gt;Everything I talked about in this post is held in a small project that does more than is explained but is mostly centered around these topics.&lt;/p&gt;

&lt;p&gt;Feel free to clone and play with the program on your own to see how it all plays together: &lt;a href="https://github.com/mwagnerPSU/ip-project"&gt;Github&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;FYI: Everything discussed in this post is location in the LocationFromIP.js file in the src folder.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>programming</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Introspection (and Mirrors?)</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 13 Dec 2021 06:52:50 +0000</pubDate>
      <link>https://dev.to/mwagner24/introspection-3291</link>
      <guid>https://dev.to/mwagner24/introspection-3291</guid>
      <description>&lt;h2&gt;
  
  
  Smart Mirror
&lt;/h2&gt;

&lt;p&gt;A project I've been thinking about making for a little while now is a smart mirror. Most people have mirrors in their bedroom and bathrooms and most people start and end their day going into the bathroom and the bedroom. I would like to build and code a smart mirror that could be utilized as a day planner, alarm clock, speaker system, and capable of all sorts of everyday tasks. &lt;/p&gt;

&lt;p&gt;The most important thing I like about the smart mirror idea is that it would be used as a tool rather than an entertainment device. People look at enough screens throughout the day, if this mirror could be used as a routine tool rather than a time waster, I'd feel like I did my job.&lt;/p&gt;

&lt;p&gt;It's definitely not a device everybody needs but it could be a device that could improve the productivity of someone's day.&lt;/p&gt;

&lt;p&gt;I originally thought of this idea as a gift for my sister and I still plan for it to be, but I do think if I'd actually build it and write the code behind it, others would want one too.&lt;/p&gt;

&lt;h2&gt;
  
  
  Money? Who needs it... Time? It's just a construct
&lt;/h2&gt;

&lt;p&gt;If I were to live life without money or time being a concern I'd like to live it seeing and experiencing everything amazing this world has to offer while helping as many people I can along the way. We live in such a remarkable time where it really feels like anything is possible. &lt;/p&gt;

&lt;p&gt;It only takes one great idea and a whole lot of drive to create something amazing. Both are tough to come by but I believe my drive stems from the wanting of making myself the best possible version I can. I then  hope to use my skills and passion to motivate and ultimately better the lives of those around me.&lt;/p&gt;

&lt;p&gt;I don't know how yet, but I'd hope one day I can either build something or have the next idea to change people's lives for the better. Looking around it seems there's so many superficial things in our lives that we put importance over the real things that make us amazing humans. When it comes down to the question, "If money was no concern, time no concern; what would you do with your life and the skills you've assembled if you could dedicate it to one thing?", I'd answer with, utilizing everything I've learned from others and through myself to dedicate myself towards the well-being of others. Whether that will be on a tech project, social service, or anything else, I want my life to make an impact on this world.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Slots for Tots - A Dive into Slots with Web Components</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 13 Dec 2021 04:07:39 +0000</pubDate>
      <link>https://dev.to/mwagner24/slots-for-tots-a-dive-into-slots-with-web-components-747</link>
      <guid>https://dev.to/mwagner24/slots-for-tots-a-dive-into-slots-with-web-components-747</guid>
      <description>&lt;h2&gt;
  
  
  What are slots?
&lt;/h2&gt;

&lt;p&gt;When writing reusable web components we come across the need to let a programmer easily enter any content they want to make the component work for their project. In a low-level sense we traditionally could use variables like this:&lt;br&gt;
&lt;code&gt;&amp;lt;div&amp;gt;${this.variable}&amp;lt;/div&amp;gt;&lt;/code&gt;&lt;br&gt;
&lt;code&gt;&amp;lt;demo-project variable="Boring text"&amp;gt;&amp;lt;/demo-project&amp;gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;This would get the job done for entering "Boring text" into our div but what if we wanted to put a &lt;code&gt;&amp;lt;ul&amp;gt;&lt;/code&gt; with 3 &lt;code&gt;&amp;lt;li&amp;gt;&lt;/code&gt; elements in place?&lt;/p&gt;

&lt;p&gt;This is where slots come in. We can take that code and create a simple slot such as this:&lt;br&gt;
&lt;code&gt;&amp;lt;div&amp;gt;&amp;lt;slot&amp;gt;&amp;lt;/slot&amp;gt;&amp;lt;/div&amp;gt;&lt;/code&gt;&lt;br&gt;
And pass our list elements in like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;demo-project&amp;gt;
  &amp;lt;ul&amp;gt;
    &amp;lt;li&amp;gt;Exciting text 1&amp;lt;/li&amp;gt;
    &amp;lt;li&amp;gt;Exciting text 2&amp;lt;/li&amp;gt;
    &amp;lt;li&amp;gt;Exciting text 3&amp;lt;/li&amp;gt;
  &amp;lt;/ul&amp;gt;
&amp;lt;/demo-project&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now we'll be able to see that entire list in our div to be used in any way we want.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why slots for tots?
&lt;/h2&gt;

&lt;p&gt;Banking of the clever slogan 'toys for tots', slots for tots (some would say is much more clever) is a way of explaining that slots enhance the ability to add custom children elements to a designated parent element. When the list above is 'slotted' into our div, that unordered list and each list element become children of our div. We are then able to go through the list and use, alter, move, etc. each element as if it was a normal ingrained list.&lt;/p&gt;

&lt;h2&gt;
  
  
  But wait! There's more...
&lt;/h2&gt;

&lt;p&gt;After using slots a few times, you might run into the issue of needing two or more slots. This becomes a problem with the code we have since our &lt;code&gt;&amp;lt;demo-project&amp;gt;&lt;/code&gt; tag only has one spot available for a slot. &lt;/p&gt;

&lt;p&gt;To fix this, we can use a named slot rather than a regular slot. Named slots give the ability to select which slot we want our custom content to go to.&lt;/p&gt;

&lt;p&gt;Let's take our &lt;code&gt;&amp;lt;demo-project&amp;gt;&lt;/code&gt; for example. If we wanted to add a header into one slot and a button into another we could do something like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div&amp;gt;
  &amp;lt;slot name=header&amp;gt;&amp;lt;/slot&amp;gt;
  &amp;lt;slot name=button&amp;gt;&amp;lt;/slot&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;demo-project&amp;gt;
  &amp;lt;span slot=header&amp;gt;&amp;lt;h2&amp;gt;Even more exciting header&amp;lt;/h2&amp;gt;&amp;lt;/span&amp;gt;
  &amp;lt;span slot=button&amp;gt;&amp;lt;button&amp;gt;Even more exciting button&amp;lt;/button&amp;gt;&amp;lt;/span&amp;gt;
&amp;lt;/demo-project&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;By naming our slots and using &lt;code&gt;slot=[name of slot]&lt;/code&gt; we're able to direct where we want our slotted content to go.&lt;/p&gt;

&lt;h2&gt;
  
  
  Having fun yet?
&lt;/h2&gt;

&lt;p&gt;I hope so because knowing how to slot content can open up a huge amount of possibilities. What if you want to slot content to other components inside your main? Sure! You can use slots to pass virtually anything, anywhere. Let's say you want to slot a header into a sub-component while slotting a list into your main component:&lt;/p&gt;

&lt;h4&gt;
  
  
  sub-component
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div&amp;gt;
  &amp;lt;slot name=header&amp;gt;&amp;lt;/slot&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  demo-project
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div&amp;gt;
  &amp;lt;sub-component&amp;gt;
    &amp;lt;h5 slot=header&amp;gt;${this.header}&amp;lt;/h5&amp;gt;
  &amp;lt;/sub-component&amp;gt;
  &amp;lt;slot&amp;gt;&amp;lt;/slot&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  demo / index.html
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;demo-project header="Most exciting header"&amp;gt;
  &amp;lt;ul&amp;gt;
    &amp;lt;li&amp;gt;Most exciting list item 1&amp;lt;/li&amp;gt;
    &amp;lt;li&amp;gt;Most exciting list item 2&amp;lt;/li&amp;gt;
    &amp;lt;li&amp;gt;Most exciting list item 3&amp;lt;/li&amp;gt;
  &amp;lt;/ul&amp;gt;
&amp;lt;/demo-project&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The result looks like this:&lt;/p&gt;

&lt;h5&gt;
  
  
  Most exciting header
&lt;/h5&gt;

&lt;ul&gt;
&lt;li&gt;Most exciting list item 1&lt;/li&gt;
&lt;li&gt;Most exciting list item 2&lt;/li&gt;
&lt;li&gt;Most exciting list item 3&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Wrap it up
&lt;/h2&gt;

&lt;p&gt;If you're interested in slots and want to look at a more in-depth use of them, I've created a project that does just that.&lt;br&gt;
Check out the &lt;a href="https://github.com/IST-402-Group-1/project-two"&gt;Github&lt;/a&gt; and feel free to install this project into your own project from &lt;a href="https://www.npmjs.com/package/@ist-402-group-1/project-two"&gt;npm&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webcomponents</category>
      <category>webdev</category>
      <category>programming</category>
    </item>
    <item>
      <title>Considerations when Designing a Web Component</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 11 Oct 2021 03:36:19 +0000</pubDate>
      <link>https://dev.to/mwagner24/considerations-when-designing-a-web-component-7po</link>
      <guid>https://dev.to/mwagner24/considerations-when-designing-a-web-component-7po</guid>
      <description>&lt;p&gt;Before we make a web component we have to understand what we're making and plan out what we want to include in the functionality of the component.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Comp
&lt;/h3&gt;

&lt;p&gt;Let's look to create a web component that displays a card. Our proposed design is to be able to make at least these three example cards with the same component.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--C4VRdyrM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iluq8f2zam9oz3pl2vg6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--C4VRdyrM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iluq8f2zam9oz3pl2vg6.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  The Breakdown
&lt;/h3&gt;

&lt;p&gt;Looking at the image we can see each card has two sections, the header, and body content.&lt;/p&gt;

&lt;p&gt;We should look at what elements are needed for each section:&lt;/p&gt;

&lt;h5&gt;
  
  
  Header
&lt;/h5&gt;

&lt;ul&gt;
&lt;li&gt;SVG Icon&lt;/li&gt;
&lt;li&gt;Header Text&lt;/li&gt;
&lt;li&gt;Sub-header Text&lt;/li&gt;
&lt;/ul&gt;

&lt;h5&gt;
  
  
  Body
&lt;/h5&gt;

&lt;ul&gt;
&lt;li&gt;Body Text&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  The Approach and Possible Challenges
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Approach
&lt;/h4&gt;

&lt;p&gt;Based on our component breakdown we can see we'll need to make two sections that can be styled independently.&lt;/p&gt;

&lt;p&gt;The header section will include our icon and two headers placed side-by-side. We can make the icon, header, and sub-header editable properties so that a user can change the content during implementation. We also need to make the background color of this section editable to set the banner color in our header.&lt;/p&gt;

&lt;p&gt;The body section has text that needs to be easily editable. Rather than making a property, like with the headings, we could utilize a slot in our body to not only make the implementation process easier but also make the content more accessible.&lt;/p&gt;

&lt;h4&gt;
  
  
  Challenges
&lt;/h4&gt;

&lt;p&gt;The biggest challenge I see is using different states to change the entire card's content. We can implement property states that will change all the text areas, icons, and colors based on a preset keyword. For example, looking at the design picture above, the third card could be a state named "question" which would dynamically change the background color of the header to blue and the icon to the question bubble. We can have several of these preset states that make it simpler for the person implementing our component.&lt;/p&gt;

&lt;h3&gt;
  
  
  Previous Experience
&lt;/h3&gt;

&lt;p&gt;Luckily, my team and I have had some experience making a web component in the past. Recently, we've made a &lt;a href="https://github.com/IST-402-Group-1/KMBtn"&gt;button&lt;/a&gt; that plays short audio clips. In this button, we've touched on some aspects of dynamic states, such as a dark mode or when the button is disabled. We should be able to use the skills we learned previously and expand upon them to make this card component as reusable and reliable as possible.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Web Component Progress</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Sat, 02 Oct 2021 02:30:16 +0000</pubDate>
      <link>https://dev.to/mwagner24/web-component-progress-3l1n</link>
      <guid>https://dev.to/mwagner24/web-component-progress-3l1n</guid>
      <description>&lt;p&gt;We are currently making a reusable button web component in one of my classes. I'm going to run through the current status of the project.&lt;/p&gt;

&lt;p&gt;When clicked the button will play a randomly picked audio clip from a selection of meme audios. Currently, the button has five properties (link, title, icon, disabled, play) that can be adjusted to personalize the button for yourself. When clicked the button plays an audio clip then opens the link in a new window. The button has functionality that will updated properties based on other properties. For example, is the play property is set to true, the button will also be disabled to prevent spamming. We also included various CSS properties to not only shape the button but change how it looks based on different states. For example, when the button is hovered over, the text and button color will change. Also, when the button is playing an audio clip, the button color will change as well.&lt;/p&gt;

&lt;p&gt;Link to repo: &lt;a href="https://github.com/IST-402-Group-1/KMBtn"&gt;https://github.com/IST-402-Group-1/KMBtn&lt;/a&gt;&lt;br&gt;
(I haven't pushed most of the changes yet)&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Web Component Frameworks</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 13 Sep 2021 04:38:34 +0000</pubDate>
      <link>https://dev.to/mwagner24/web-component-frameworks-4h1k</link>
      <guid>https://dev.to/mwagner24/web-component-frameworks-4h1k</guid>
      <description>&lt;p&gt;Ever been confused by web programming? No? ...stop lying&lt;/p&gt;

&lt;p&gt;JavaScript runs the majority of web pages and with JS we can create custom web components. Since web components are relatively new they may be tough to pick up and implement. To ease the pain we all feel, people have made frameworks to slightly ease the burden of creating web components.&lt;/p&gt;

&lt;p&gt;We'll compare some of the most popular frameworks (Angular, Vue, React) and a toolchain (Stencil) to determine the pluses and minuses that apply across them.&lt;/p&gt;

&lt;h3&gt;
  
  
  Commonalities
&lt;/h3&gt;

&lt;p&gt;Angular, React and Stencil are all similar in the way they conduct their file structures. Package.json is located in the main directory while the main page content is located in a designated folder. The outlier, Vue holds all the main content in the root directory. Misleadingly, Vue also puts .vue files in the /src folder which could be seen as confusing to a vanillaJS veteran.&lt;/p&gt;

&lt;p&gt;Angular and Stencil use typescript which makes a newbie shiver but can be learned fairly quickly with experience in JS. On the other hand, React and Vue run (frontend-wise) on JS.&lt;/p&gt;

&lt;h3&gt;
  
  
  Duplicate / Overlapping Frameworks
&lt;/h3&gt;

&lt;p&gt;Once you begin using each framework, you begin to notice a good amount of how they work overlaps with each other. We get this duplication since these frameworks are open to use and shape into any project anybody wants. This makes contributors adding the effective parts of other frameworks to the one your using.&lt;/p&gt;

&lt;h3&gt;
  
  
  Easiest vs. Bias
&lt;/h3&gt;

&lt;p&gt;Overall, Vue seems the easiest to use since it's not very complicated to learn and running with.&lt;/p&gt;

&lt;p&gt;But who likes doing the easy one?&lt;/p&gt;

&lt;p&gt;I've had experience in a past internship with Angular and although Vue wouldn't be tough to pick up if needed, if I had to choose a one to get a website going today, I'd be more confident in using Angular.&lt;/p&gt;

&lt;h3&gt;
  
  
  GitHub
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://github.com/IST-402-Group-1/IST402"&gt;Group Repo&lt;/a&gt;&lt;br&gt;
&lt;a href="https://github.com/mwagnerPSU/IST402/"&gt;My Fork with Boilerplate&lt;/a&gt;&lt;br&gt;
&lt;a href="https://github.com/hartjus/stencil-hello-world"&gt;Stencil Hello-World Boilerplate&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Getting started with open-wc</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 30 Aug 2021 04:06:37 +0000</pubDate>
      <link>https://dev.to/mwagner24/getting-started-with-open-wc-4m1h</link>
      <guid>https://dev.to/mwagner24/getting-started-with-open-wc-4m1h</guid>
      <description>&lt;p&gt;In this post we'll go through all the steps to set up a web component using open-wc in windows. We'll go through the needed dependencies and steps to get a web component going.&lt;/p&gt;

&lt;h3&gt;Before we start&lt;/h3&gt;

&lt;p&gt;We need a few things before creating a web component. First we'll install Node.js from their &lt;a href="https://nodejs.org/en/download/"&gt;website&lt;/a&gt;. Next, we'll install npm by opening a command prompt and typing&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It is optional to also install yarn which can be done with your command prompt as well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm install -g yarn
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;Creating a Web Component&lt;/h3&gt;

&lt;p&gt;Now we're ready to actually create a web component.&lt;/p&gt;

&lt;p&gt;Start by using the command prompt to go into your desired folder. For example, &lt;code&gt;cd "project folder"&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Then initiate the web component by using this command.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm init @open-wc
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We now have a few options to pick from.&lt;/p&gt;

&lt;p&gt;First we can can choose to scaffold a new project or expand upon an existing one. To create a new component we'll pick the scaffolding option by using the arrow keys and pressing the space bar. &lt;/p&gt;

&lt;p&gt;Next, we can choose between creating a web component or an application. We'll choose a web component. &lt;/p&gt;

&lt;p&gt;The third set of choices are optional and will determine what will be set up automatically. Use the space bar to select your options, I choose to select all of them. To move on click the enter key. &lt;/p&gt;

&lt;p&gt;Then we choose whether to use typescript or not. I choose not to. &lt;/p&gt;

&lt;p&gt;Enter a name for your web component. &lt;/p&gt;

&lt;p&gt;Now, we'll choose to write the proposed file structure to the disk and pick what dependencies to setup the web component with. You can choose to install with npm or if you previously installed yarn you can install using yarn.&lt;/p&gt;

&lt;p&gt;You're all set!&lt;/p&gt;

&lt;h3&gt;Running and Editing your Web Component&lt;/h3&gt;

&lt;p&gt;The web component we just created can be ran by changing the directory in the command prompt to the folder that has been created. Ex. &lt;code&gt;cd test-project&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Then running the component with, &lt;code&gt;npm run start&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Lastly, to edit the component in VS Code use the same commands as previously to change the directory to the project folder then type the command, &lt;code&gt;code .&lt;/code&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Introduction</title>
      <dc:creator>Interaction Designs</dc:creator>
      <pubDate>Mon, 30 Aug 2021 03:06:42 +0000</pubDate>
      <link>https://dev.to/mwagner24/introduction-5hbd</link>
      <guid>https://dev.to/mwagner24/introduction-5hbd</guid>
      <description>&lt;p&gt;Hi everyone! I'm Mike Wagner and unfortunately starting my senior year this year. My major is IST in the Human Centered Design and Development branch. I started at Penn State in engineering but found after freshman year I enjoy the tech realm more.&lt;/p&gt;

&lt;p&gt;I have a decent amount of experience and knowledge with web development from other classes but also have been introduced and somewhat worked with web components from taking IST 402 last semester.&lt;/p&gt;

&lt;p&gt;I'm excited for this class and making a memorable last year!&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
