<?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: Nicolas Maloeuvre</title>
    <description>The latest articles on DEV Community by Nicolas Maloeuvre (@nicolasmlv).</description>
    <link>https://dev.to/nicolasmlv</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%2F122349%2F2f8f8e35-236e-4915-87c8-d45e4327e20d.jpeg</url>
      <title>DEV Community: Nicolas Maloeuvre</title>
      <link>https://dev.to/nicolasmlv</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/nicolasmlv"/>
    <language>en</language>
    <item>
      <title>I built a Portfolio &amp; Blog Website using nothing but HTML !</title>
      <dc:creator>Nicolas Maloeuvre</dc:creator>
      <pubDate>Thu, 07 Jan 2021 05:07:22 +0000</pubDate>
      <link>https://dev.to/nicolasmlv/i-built-a-portfolio-blog-website-using-nothing-but-html-mbg</link>
      <guid>https://dev.to/nicolasmlv/i-built-a-portfolio-blog-website-using-nothing-but-html-mbg</guid>
      <description>&lt;h2&gt;
  
  
  What I built
&lt;/h2&gt;

&lt;p&gt;A template of a static Portfolio &amp;amp; Blog website with Tailwind CSS.&lt;/p&gt;

&lt;h3&gt;
  
  
  Category Submission
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Personal Site/Portfolio&lt;/strong&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  App Link
&lt;/h3&gt;

&lt;p&gt;Reusable template : &lt;a href="https://tailwind-blog-portfolio-sample-jdnb6.ondigitalocean.app/" rel="noopener noreferrer"&gt;https://tailwind-blog-portfolio-sample-jdnb6.ondigitalocean.app/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;extracted from my website : &lt;a href="https://www.nicomlv.com" rel="noopener noreferrer"&gt;https://www.nicomlv.com&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Screenshots
&lt;/h3&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%2Fi%2Fc7va9ly57ywj2vzw3ec9.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%2Fi%2Fc7va9ly57ywj2vzw3ec9.png" alt="Home Page"&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%2Fi%2Fame3b3j90vjy6mlxtqja.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%2Fi%2Fame3b3j90vjy6mlxtqja.png" alt="Home Page - Portfolio"&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%2Fi%2Frwwgkojoon3hvlrlhojd.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%2Fi%2Frwwgkojoon3hvlrlhojd.png" alt="Bio Page"&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%2Fi%2Fkyolgrbg4tdozhigjezi.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%2Fi%2Fkyolgrbg4tdozhigjezi.png" alt="Blog entry page"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Description
&lt;/h3&gt;

&lt;p&gt;There are 4 pages :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Home with portfolio&lt;/li&gt;
&lt;li&gt;Blog, with Rss and Atom and JSON feeds&lt;/li&gt;
&lt;li&gt;Two blog entries, with highlight.js integrated : you can easily highlight your code in any language&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It is a template, you can fork it and make your changes, live-reloading is fast and integrated (no need to refresh the browser). Tailwind CSS is a utility-first CSS library, it means you don't need to write any CSS, you use classes like "text-red-500" or "mt-10" (it means margin-top: 10px) or "animate-spin" (it spins your element) etc... It also means that it is very easy to re-use code snippets you can find on &lt;a href="https://tailwindcss.com/" rel="noopener noreferrer"&gt;https://tailwindcss.com/&lt;/a&gt; or &lt;a href="https://www.tailwindtoolbox.com/" rel="noopener noreferrer"&gt;https://www.tailwindtoolbox.com/&lt;/a&gt; &lt;/p&gt;

&lt;h3&gt;
  
  
  Link to Source Code
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://github.com/nicolasmlv/tailwind-blog-portfolio-sample" rel="noopener noreferrer"&gt;https://github.com/nicolasmlv/tailwind-blog-portfolio-sample&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Permissive License
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://choosealicense.com/licenses/mit/" rel="noopener noreferrer"&gt;MIT&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;My first resolution for 2021 was to create a website with a blog, so I created it, as a static website with Tailwind CSS. My &lt;a href="https://www.nicomlv.com/blog/tutorial-simple-html-tailwind-setup" rel="noopener noreferrer"&gt;first blog entry&lt;/a&gt; was about how to setup Tailwind CSS. I re-posted it on dev.to, and there I found the DigitalOcean Hackathon, and I thought it would be great to extract a template of my blog setup for the Hackathon, with a DigitalOcean Button, and host it on DigitalOcean (hint : the performance are way better than the other hosting provider I had in the first time.)&lt;/p&gt;

&lt;h3&gt;
  
  
  How I built it
&lt;/h3&gt;

&lt;p&gt;I wanted to not use any JS Framework, only Tailwind CSS and HTML. It was harder than I thought because I am a very bad frontend programmer who did not know npm and postcss, but now it is ok : skill acquired.&lt;/p&gt;

&lt;p&gt;Then I spent some times reading and learning about Open Graph, Twitter Card, RSS feed, Atom feed, JSON feed, meta properties, and implemented them.&lt;/p&gt;

&lt;p&gt;When I wanted to push my code to DigitalOcean's App Platform, there was nothing to do : just link my Github, choose the repo and specify "static site" : it works. Because DigitalOcean recognize "public" as the folder to serve, and I used this one.&lt;/p&gt;

&lt;p&gt;There is one thing that was not working, it is that DigitalOcean will not serve your html file without the &lt;code&gt;.html&lt;/code&gt;. Example : &lt;code&gt;/blog/welcome-to-my-blog&lt;/code&gt; will not serve your &lt;code&gt;/blog/welcome-to-my-blog.html&lt;/code&gt; but it will serve &lt;code&gt;/blog/welcome-to-my-blog/index.html&lt;/code&gt;. And actually it is not a bug but a feature, because it is better to create a folder for the blog entry and put the images of the blog entry in this same folder, so I have a better code organization now.&lt;/p&gt;

&lt;h3&gt;
  
  
  Additional Resources/Info
&lt;/h3&gt;

&lt;p&gt;I added the DigitalOcean Button in the Readme, it was very easy, I just had to copy-paste from the &lt;a href="https://www.digitalocean.com/docs/app-platform/how-to/add-deploy-do-button/" rel="noopener noreferrer"&gt;documentation (see static sites)&lt;/a&gt; the &lt;code&gt;.do/deploy.template.yaml&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;I know the title is a bit misleading 😄 I wrote one line of JS  (inline-style 🙀) :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;button&lt;/span&gt; &lt;span class="na"&gt;onclick=&lt;/span&gt;&lt;span class="s"&gt;"document.getElementById('pronunciation').play();"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;🔊&lt;span class="nt"&gt;&amp;lt;/button&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Oh this one too :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;script &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"/highlight.pack.js"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;script&amp;gt;&lt;/span&gt;&lt;span class="nx"&gt;hljs&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;initHighlightingOnLoad&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;&lt;span class="nt"&gt;&amp;lt;/script&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And this CSS :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="k"&gt;@layer&lt;/span&gt; &lt;span class="n"&gt;components&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="err"&gt;@apply&lt;/span&gt; &lt;span class="err"&gt;underline&lt;/span&gt; &lt;span class="py"&gt;focus&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;outline-black&lt;/span&gt; &lt;span class="n"&gt;bg-gradient-to-r&lt;/span&gt; &lt;span class="n"&gt;hover&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;text-white&lt;/span&gt; &lt;span class="n"&gt;hover&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;from-pink-500&lt;/span&gt; &lt;span class="n"&gt;hover&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="n"&gt;to-yellow-500&lt;/span&gt; &lt;span class="n"&gt;py-1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;for links on hover (I am very bad at design) :&lt;br&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%2Fi%2Ffhw8gqf7r9rin13xssuj.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%2Fi%2Ffhw8gqf7r9rin13xssuj.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>dohackathon</category>
      <category>tailwindcss</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Tutorial Simple HTML website Tailwind Setup</title>
      <dc:creator>Nicolas Maloeuvre</dc:creator>
      <pubDate>Sun, 03 Jan 2021 04:02:50 +0000</pubDate>
      <link>https://dev.to/nicolasmlv/tutorial-simple-html-website-tailwind-setup-cma</link>
      <guid>https://dev.to/nicolasmlv/tutorial-simple-html-website-tailwind-setup-cma</guid>
      <description>&lt;p&gt;&lt;iframe width="710" height="399" src="https://www.youtube.com/embed/6BViyXWxARg"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;I wanted to create a simple static website with Tailwind, but unfortunately I am not a frontend programmer, I could not understand the official Tailwind Documentation on how to get started, so here is the tutorial that would have helped me be operational in minutes.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;my-static-website &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;cd &lt;/span&gt;my-static-website
&lt;span class="c"&gt;# by default, npm think you will publish your project as a npm package and so it asks for your name, your email etc, weird, ignore this with “-y” &lt;/span&gt;
npm init &lt;span class="nt"&gt;-y&lt;/span&gt;
npm &lt;span class="nb"&gt;install &lt;/span&gt;autoprefixer cssnano onchange postcss postcss-cli tailwindcss cross-env live-server
&lt;span class="c"&gt;# it will install 1000 packages, the mythical frontend bloat was not a myth after all, keep them for you :&lt;/span&gt;
&lt;span class="nb"&gt;touch&lt;/span&gt; .gitignore &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"node_modules/"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; .gitignore
&lt;span class="c"&gt;# generate your tailwind.config.js file, (npx is a cli tool for npm packages)&lt;/span&gt;
npx tailwindcss init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Edit the "purge" config in &lt;strong&gt;tailwind.config.js&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;purge&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;mode&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;all&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;preserveHtmlElements&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;./public/**/*.html&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;},&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;On &lt;strong&gt;package.json&lt;/strong&gt;, remove the test script and set this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="nl"&gt;"scripts"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"buildcss:dev"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"tailwindcss build ./main.css -o public/styles.css"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"buildcss:prod"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"cross-env NODE_ENV=production postcss build ./main.css -o ./public/styles.css"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"onchange"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"onchange 'tailwind.config.js' 'main.css' -- npm run buildcss:dev"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"serve"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"live-server public"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create &lt;strong&gt;postcss.config.js&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;cssnano&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;cssnano&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;module&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;exports&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;plugins&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="nx"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;tailwindcss&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="nx"&gt;cssnano&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
      &lt;span class="na"&gt;preset&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;default&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;}),&lt;/span&gt;
    &lt;span class="nx"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;autoprefixer&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
  &lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create &lt;strong&gt;Readme.md&lt;/strong&gt; (and read it):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gh"&gt;# My static website&lt;/span&gt;

&lt;span class="gu"&gt;## Run in dev mode&lt;/span&gt;

In dev mode you need the full heavy tailwind.css because when you add Tailwind classes in your HTML, it will works directly, in some milliseconds. Be sure to run : &lt;span class="sb"&gt;`npm run buildcss:dev`&lt;/span&gt; if you use &lt;span class="sb"&gt;`commit_and_push.sh`&lt;/span&gt; you don't need it.

When you need to edit your tailwind.config.js (like testing colors) or your custom CSS (&lt;span class="sb"&gt;`main.css`&lt;/span&gt;), you can run &lt;span class="sb"&gt;`npm run onchange`&lt;/span&gt; on one tab, to see those edits live. You don't need it if you only edit your HTML with Tailwind classes.

&lt;span class="gu"&gt;## Run in production&lt;/span&gt;

Compile and commit a light tailwind.css file with &lt;span class="sb"&gt;`npm run buildcss:prod`&lt;/span&gt;. If you use &lt;span class="sb"&gt;`./commit_and_push.sh "commit message"`&lt;/span&gt;, you don't need to run it.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create &lt;strong&gt;commit_and_push.sh&lt;/strong&gt; or run it manually when needed if you prefer:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm run buildcss:prod
git add &lt;span class="nb"&gt;.&lt;/span&gt; &lt;span class="nt"&gt;-A&lt;/span&gt;
git commit &lt;span class="nt"&gt;-am&lt;/span&gt; &lt;span class="nv"&gt;$1&lt;/span&gt;
git push
npm run buildcss:dev
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create &lt;strong&gt;main.css&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="k"&gt;@tailwind&lt;/span&gt; &lt;span class="n"&gt;base&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@tailwind&lt;/span&gt; &lt;span class="n"&gt;components&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@tailwind&lt;/span&gt; &lt;span class="n"&gt;utilities&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c"&gt;/* add your custom CSS here if you need */&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create &lt;strong&gt;public/index.html&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;meta&lt;/span&gt; &lt;span class="na"&gt;charset=&lt;/span&gt;&lt;span class="s"&gt;"utf-8"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;My static page&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;link&lt;/span&gt; &lt;span class="na"&gt;rel=&lt;/span&gt;&lt;span class="s"&gt;"stylesheet"&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"/styles.css"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Content&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you are ready. Generate for the first time the heavy Tailwind with &lt;strong&gt;npm run buildcss:dev&lt;/strong&gt;. Accordingly to your Readme, run &lt;strong&gt;npm run onchange&lt;/strong&gt; and &lt;strong&gt;npm run serve&lt;/strong&gt; in your terminal, add some Tailwind classes, edit your tailwind.config.js, add new HTML pages, it's working.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ship it
&lt;/h2&gt;

&lt;p&gt;You don't want to use the full tailwind css (4Mb) on production, &lt;strong&gt;buildcss:prod&lt;/strong&gt; generates a light one. When you edit your HTML though, you prefer to use &lt;strong&gt;buildcss:dev&lt;/strong&gt; because it is faster.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Create a Github repository&lt;/li&gt;
&lt;li&gt;Create a render.com account (or Netlify, or similar), "New" / "Static site", and link your repository. Edit "Public directory" to : "./public".&lt;/li&gt;
&lt;li&gt;Commit a new edit in order to trigger the build, it works.&lt;/li&gt;
&lt;li&gt;Add your domain, add the A and CNAME entry, wait 5 minutes and it is live on your domain 👍&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you have any question or suggestion, please comment&lt;/p&gt;

</description>
      <category>dohackaton</category>
      <category>tailwindcss</category>
      <category>npm</category>
      <category>beginners</category>
    </item>
    <item>
      <title>How to reduce your APM Cost with this one-liner</title>
      <dc:creator>Nicolas Maloeuvre</dc:creator>
      <pubDate>Wed, 16 Oct 2019 09:36:45 +0000</pubDate>
      <link>https://dev.to/nicolasmlv/how-to-reduce-your-apm-cost-with-this-one-liner-30bp</link>
      <guid>https://dev.to/nicolasmlv/how-to-reduce-your-apm-cost-with-this-one-liner-30bp</guid>
      <description>&lt;p&gt;If the pricing of you APM is based on the number of transactions, it might interest you.&lt;/p&gt;

&lt;p&gt;First, spot your most used transactions in the APM. In Scout, use "Highest throughput" (you will find the same in New Relic, Datadog, Librato, AppSignal, Skylight, etc) :&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--DIgn3Zz0--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/expk8ot1w1mtosjjy8po.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--DIgn3Zz0--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/expk8ot1w1mtosjjy8po.png" alt="screenshot of Scout select input"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Then, register only 1/10th of them for example. If you use ScoutAPM and Ruby on Rails, add this in the controller :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  ScoutApm::Transaction.ignore! if rand(10) &amp;gt; 0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;done!&lt;/p&gt;

&lt;p&gt;Obviously, the drawback is that you will miss some data, but the "mean response time per request" should still give an honest idea of the reality.&lt;/p&gt;

&lt;p&gt;It will depend on your needs, maybe do not use it in your main home webpage, but it can be useful to use it on that little api request that is done each time after this home webpage is loaded.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>devops</category>
      <category>rails</category>
      <category>ruby</category>
    </item>
  </channel>
</rss>
