<?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: Timothy Robards</title>
    <description>The latest articles on DEV Community by Timothy Robards (@timothyrobards).</description>
    <link>https://dev.to/timothyrobards</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%2F475910%2Fd6f3dc25-a676-4289-bc8a-ad893c600506.jpeg</url>
      <title>DEV Community: Timothy Robards</title>
      <link>https://dev.to/timothyrobards</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/timothyrobards"/>
    <language>en</language>
    <item>
      <title>Discovering the Benefits of Freelance Work</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Fri, 16 Feb 2024 17:04:17 +0000</pubDate>
      <link>https://dev.to/timothyrobards/discovering-the-benefits-of-freelance-work-f51</link>
      <guid>https://dev.to/timothyrobards/discovering-the-benefits-of-freelance-work-f51</guid>
      <description>&lt;p&gt;For countless freelancers, its allure lies in the ability to &lt;strong&gt;be your own boss&lt;/strong&gt;, &lt;strong&gt;set your own schedule&lt;/strong&gt;, and &lt;strong&gt;work from any location&lt;/strong&gt; you like. Others are drawn by the potential for financial growth, ample opportunities for personal and professional development, or the freedom to select projects that align with your passions. Whatever the driving force may be, &lt;strong&gt;it’s an exciting time to become a freelancer&lt;/strong&gt;!&lt;/p&gt;

&lt;p&gt;Furthermore, the tech industry presents vast opportunities for freelancers. Whether you specialize in web development, design, writing, marketing, social media management — or any skill set involving a keyboard — you’re well-poised to reap the numerous benefits that freelancing has to offer.&lt;/p&gt;

&lt;p&gt;In this article, we look at some of the main reasons why people choose to become freelancers. I bet that if any of these reasons resonate with you, chances are high that you’ll thoroughly enjoy working for yourself as a freelancer!&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Be Your Own Boss 😎
&lt;/h3&gt;

&lt;p&gt;One of the main reasons many choose to start freelancing is the ability to &lt;strong&gt;be your own boss&lt;/strong&gt;. The idea of saying goodbye to controlling managers, not feeling valued, or rewarded for your hard work, is often reason enough! But perhaps more accurately, it’s an &lt;strong&gt;entrepreneurial spirit&lt;/strong&gt; that attracts many to the world of freelancing.&lt;/p&gt;

&lt;p&gt;And let’s be real, who doesn’t want this coffee mug…&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%2F5fi79a5wtzuwstsy2cy6.jpeg" 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%2F5fi79a5wtzuwstsy2cy6.jpeg" alt="World's best boss coffee mug"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;‘THE’ coffee mug for the self-employed.&lt;/p&gt;

&lt;p&gt;Additionally, being your own boss is likely to unearth new levels of creativity, motivation and innovation that will have you feeling inspired and ready to take on anything! It’s a fantastic reason to get into freelancing.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Work on your own terms 🛠️
&lt;/h3&gt;

&lt;p&gt;Do you want to exclusively build websites using &lt;a href="https://wordpress.org/" rel="noopener noreferrer"&gt;WordPress&lt;/a&gt;? &lt;/p&gt;

&lt;p&gt;Or specialize in e-commerce websites with &lt;a href="https://www.shopify.com/" rel="noopener noreferrer"&gt;Shopify&lt;/a&gt;? &lt;/p&gt;

&lt;p&gt;Do you desire the freedom to change your mind at any time, without requiring someone else’s permission? &lt;/p&gt;

&lt;p&gt;As a freelancer, you’re not bound by the requirements of others — you make all the rules.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Work when you want ⏰
&lt;/h3&gt;

&lt;p&gt;Are you most productive in the morning or at night? &lt;/p&gt;

&lt;p&gt;There’s no reason to adhere to a traditional 9-to-5 schedule if it doesn’t suit you. You could work from 4 a.m. to 8 a.m. if that aligns better with your productivity peaks. &lt;/p&gt;

&lt;p&gt;The same flexibility applies to the typical 5-day work week. If you can achieve all your goals in 4 days, there’s nothing stopping you. Go for it!&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Work where you want 🌴
&lt;/h3&gt;

&lt;p&gt;Another truly great thing about freelancing is that you can &lt;strong&gt;work from anywhere&lt;/strong&gt;! It doesn’t matter to your clients, as long as you get the job done. So, if you enjoy traveling or perhaps even aspire to embrace the digital nomad lifestyle, you’ll love the freedom of being your own boss! &lt;/p&gt;

&lt;p&gt;Even if you don’t travel often (or at all), you’re free to work in coffee shops, in the backyard, at the park, or in your hotel if you decide to book a week away.&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%2Fr3w6vpqvbg1uoew0bl7h.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%2Fr3w6vpqvbg1uoew0bl7h.jpg" alt="Zen freelancer"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Unlimited earning potential 💸
&lt;/h3&gt;

&lt;p&gt;When you’re starting out, you’ll likely accept most of the work you can get. However, as time goes on, you’ll find yourself with more opportunities than you can handle alone. &lt;/p&gt;

&lt;p&gt;At this juncture, you have the luxury of being selective and, better yet, you can raise your rates. Clients seeking a dependable freelancer or your specialized type of work will gladly pay these higher rates. &lt;/p&gt;

&lt;p&gt;As your business advances, your earnings potential really becomes limitless.&lt;/p&gt;

&lt;h3&gt;
  
  
  6. Unlimited growth opportunities 🌱
&lt;/h3&gt;

&lt;p&gt;There will come a time when you’ll contemplate outsourcing aspects of your business or even expanding it into an agency capable of offering a wide range of services. &lt;/p&gt;

&lt;p&gt;Should you choose to establish a company, recruit staff, and develop a brand, you’ll embark on a journey impossible to achieve as an employee. &lt;/p&gt;

&lt;p&gt;Remember that &lt;strong&gt;great things often come from humble beginnings.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Whether you ultimately reach this level or not, the freelance journey will undoubtedly foster positive growth within you.&lt;/p&gt;

&lt;p&gt;How? &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You’ll learn more than you anticipate.&lt;/strong&gt; Each day in the freelance realm presents a fresh array of challenges, providing ample opportunities for growth. Beyond being a designer, writer, or developer, you’ll assume the role of a business owner, honing your problem-solving skills daily. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You’ll cultivate resilience.&lt;/strong&gt; Freelancing often requires navigating unpredictable situations and overcoming setbacks. As you confront and conquer these challenges, you’ll develop a robust resilience that strengthens your ability to bounce back from adversity, both personally and professionally.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You’ll gain confidence.&lt;/strong&gt; With each day, you’ll manage client interactions, sales, and meetings. These tasks will quickly become second nature. Others will begin to perceive and treat you differently. As a freelancer, you’ll witness a significant boost in your everyday confidence.&lt;/p&gt;

&lt;h3&gt;
  
  
  7. Choose projects that you want to work on 🖥️
&lt;/h3&gt;

&lt;p&gt;Another fantastic aspect of freelancing is the freedom to select projects that resonate with you. &lt;/p&gt;

&lt;p&gt;Whether you’re a web developer specializing in large-scale eCommerce websites, a designer focusing on logo creation, or a writer who wants to only write ad copy, the choice is yours! You have the freedom to pursue what aligns with your passions and inspires you the most. &lt;/p&gt;

&lt;p&gt;It’s important to remember that you’ll inevitably need to do some repetitive work (such as admin tasks, accounting, etc.) that are part of the job. However, if the job itself is something you’ve chosen to do because it’s something you enjoy, then you’re going to find the task itself much more rewarding.&lt;/p&gt;

&lt;h3&gt;
  
  
  8. Know when to say no! 🚫
&lt;/h3&gt;

&lt;p&gt;Regrettably, many freelancers encounter difficult clients at some point. This is particularly common in the early stages when you’re eager to accept any available work. &lt;/p&gt;

&lt;p&gt;It’s crucial to recognize that &lt;strong&gt;you have the power&lt;/strong&gt; to choose your clients. And clients must respect the boundaries outlined in your freelance contract (more details on that in a forthcoming article!). However, if a client displays aggression, rudeness, or fails to respect your time, you have the right to terminate the contract immediately. Losing a project is a small price to pay for safeguarding your mental well-being, which is paramount. &lt;/p&gt;

&lt;p&gt;Knowing when to say &lt;strong&gt;“No”&lt;/strong&gt; is a valuable skill both in business and life.&lt;/p&gt;

&lt;h3&gt;
  
  
  9. Reap the Rewards of Your Efforts 👏
&lt;/h3&gt;

&lt;p&gt;We’re all familiar with the typical employee setup: a fixed salary, occasional bonuses, and an annual raise that barely keeps pace with inflation. Even if you work tirelessly, put in extra hours, and boost your employer’s profits, your paycheck remains unchanged. Where’s the incentive? &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;As a freelancer, you’re compensated for your dedication&lt;/strong&gt;. If you go above and beyond, work extra hours, and deliver exceptional results for your clients, you’ll see a direct increase in your income. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Every ounce of effort you invest benefits you directly&lt;/strong&gt;, not someone else. So, go ahead and relish in the extra earnings you’ve rightfully earned! (Or save it up if that’s more your style 😜).&lt;/p&gt;

&lt;h3&gt;
  
  
  10. Experience Unmatched Job Security 💪
&lt;/h3&gt;

&lt;p&gt;As a freelancer, your job security is unparalleled (unless, of course, you choose to let yourself go?). &lt;strong&gt;Your primary responsibility is to persevere!&lt;/strong&gt; &lt;/p&gt;

&lt;p&gt;In the long term, you’ll have complete control over your future and income. This level of autonomy far exceeds the sense of ‘job security’ associated with traditional employment, where a company can abruptly terminate your services at any moment.&lt;/p&gt;

&lt;h3&gt;
  
  
  So, why do YOU want to freelance?
&lt;/h3&gt;

&lt;p&gt;Take some time to reflect on &lt;strong&gt;what matters most to you&lt;/strong&gt;. Some of the points mentioned here may resonate more strongly with you than others, or you may have your own unique set of reasons.&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%2Fmvb5zx5dlao7kw5moam0.gif" 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%2Fmvb5zx5dlao7kw5moam0.gif" alt="Up to you meme"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For me personally, the daily satisfaction of knowing that my hard work directly translates into tangible rewards is priceless. &lt;/p&gt;

&lt;p&gt;Whether it’s witnessing my business grow, building stronger relationships with clients, or just taking a moment to appreciate the freedom and flexibility of freelancing, it’s definitely a great feeling to be in control of my own destiny.&lt;/p&gt;

&lt;p&gt;Remember, exploring the freelance life is an ongoing journey of self-discovery and growth, so stay open to new opportunities and possibilities along the way.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&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%2Fq8jx3gvzvjazn8z1mbjm.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%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>beginners</category>
      <category>freelance</category>
      <category>design</category>
    </item>
    <item>
      <title>15 Best Platforms to Find Freelance Work</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Thu, 01 Feb 2024 14:35:29 +0000</pubDate>
      <link>https://dev.to/timothyrobards/15-best-platforms-to-find-freelance-work-4b0</link>
      <guid>https://dev.to/timothyrobards/15-best-platforms-to-find-freelance-work-4b0</guid>
      <description>&lt;p&gt;Everyone wants to make money through freelancing, but it’s not always easy to get started! &lt;/p&gt;

&lt;p&gt;Platforms (Upwork, Codementor, etc) are an ideal place to find clients when you’re new to freelancing and you haven’t yet built your own client base. Most of the time the tasks on offer are quick and one-off, but they’re an excellent way to start building your reputation and gaining experience.&lt;/p&gt;

&lt;p&gt;By using a platform, you can rapidly build a client base with minimal effort, and find a ton of jobs in just a few clicks. You’ll also benefit from the added contract security, automated invoicing, time-management software &amp;amp; more! The result is a fairly substantial saving in terms of both time and money.&lt;/p&gt;

&lt;p&gt;It’s important to choose the right platform based on your skills. So here’s a comparison of the top 15 freelancing platforms for freelancers.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Upwork
&lt;/h2&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%2F6zmi18pa9n6t70cv79p4.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%2F6zmi18pa9n6t70cv79p4.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.upwork.com/" rel="noopener noreferrer"&gt;Upwork&lt;/a&gt; has a massive user base (1.5 million clients and growing), so it goes without saying that there are a ton of freelance opportunities to pick from. There are short and long-term jobs for web developers, designers, writers and more. Whatever your skill level, the vast availability of jobs all but guarantees you will find work on Upwork. &lt;/p&gt;

&lt;p&gt;However, the popularity of the platform is a kind of double-edged sword. Yes, there are a ton of opportunities, but also a LOT of competition. Many projects will have 30–40 bidders which makes it quite difficult to stand out. This can often mean that you’ll find yourself needing to work for less than your worth in order to secure a contract — which isn’t ideal.&lt;/p&gt;

&lt;p&gt;That being said, some freelancers do very well on Upwork and secure high-paying projects with good consistency. Upwork can be worth the time — if you’re willing to put in the work to establish your reputation on the platform. &lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Access to an endless supply of jobs&lt;/li&gt;
&lt;li&gt;Highly flexible&lt;/li&gt;
&lt;li&gt;Well-organized&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The massive amount of competition forces you to lower your rate&lt;/li&gt;
&lt;li&gt;Fees are much higher than other platforms&lt;/li&gt;
&lt;li&gt;If your account ever gets suspended, your payments will be locked&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. Freelancer
&lt;/h2&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%2Fqvfbbksj7kq6i0om9k5g.jpeg" 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%2Fqvfbbksj7kq6i0om9k5g.jpeg" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.freelancer.com/" rel="noopener noreferrer"&gt;Freelancer&lt;/a&gt; is considered by many to be one of the biggest and best platforms to find work. Much like Upwork, you’ll find work as a developer, designer, writer or even SEO specialist. The site is easy to navigate for both freelancers and clients alike. One unique thing about this platform is that freelancers are able to keep 100% of their earnings, unlike most of the other platforms whose fees and rates vary.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Choose your work and set your own timing&lt;/li&gt;
&lt;li&gt;Large range of jobs to choose from&lt;/li&gt;
&lt;li&gt;A “free membership” option is available if you want to try out the platform &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Highly competitive&lt;/li&gt;
&lt;li&gt;Difficult to get started when you haven't received any feedback&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  3. Toptal
&lt;/h2&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%2F3mmc1x08lc57bm8uksuh.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%2F3mmc1x08lc57bm8uksuh.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.toptal.com/" rel="noopener noreferrer"&gt;Toptal&lt;/a&gt; is a great solution for more experienced freelancers. They position themselves as the place to find the top 3% of freelance talent. In order to access the platform you’ll need to pass a rigorous screening test — the reward is access to great clients (Airbnb, Zendesk, etc..) with substantive projects, along with competitive compensation. This exclusivity sets them apart from many of their peers.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Fantastic for experienced freelancers &lt;/li&gt;
&lt;li&gt;Big-name clients&lt;/li&gt;
&lt;li&gt;Great compensation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Difficult to access the platform without substantial experience&lt;/li&gt;
&lt;li&gt;Not ideal for beginners&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  4. Fiverr
&lt;/h2&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%2Forqepfylmhh4camfhvsv.jpeg" 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%2Forqepfylmhh4camfhvsv.jpeg" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.fiverr.com" rel="noopener noreferrer"&gt;Fiverr&lt;/a&gt; works differently from traditional platforms. As a freelancer, you create your own jobs based on your abilities — instead of having companies post jobs to apply for. You can do well by categorizing your “gigs” by using keywords that show up in different search queries. And although the name implies that the cost is just $5 per project, this isn’t a requirement — just a starting point. However, this does mean that most clients on the platform are not expecting to pay much for a project.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ideal for beginners looking to get some experience&lt;/li&gt;
&lt;li&gt;Trustworthy company&lt;/li&gt;
&lt;li&gt;By offering the services yourself, you’ll be working in your comfort zone&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It is very competitive&lt;/li&gt;
&lt;li&gt;Low earnings&lt;/li&gt;
&lt;li&gt;Better options exist if you're looking to make money&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  5. Codementor
&lt;/h2&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%2Fjsvwlpq1i9liin83tu0d.jpeg" 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%2Fjsvwlpq1i9liin83tu0d.jpeg" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.codementor.io" rel="noopener noreferrer"&gt;Codementor&lt;/a&gt; is a great alternative to many online platforms. Essentially you join the platform as a “mentor” to share your expertise, teach &amp;amp; answer coding-related questions in real-time. These sessions can take the form of video chat (including screen-sharing) or chat-based interaction. Clients are often new to web development &amp;amp; are looking for mentorship, one-on-one help or debugging. If you’re an intermediate to advanced level developer with a strong interest in teaching — Codementor is a great way to find freelance work!&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You get paid to teach code!&lt;/li&gt;
&lt;li&gt;Highly responsive staff&lt;/li&gt;
&lt;li&gt;Flexible scheduling&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Not cost-effective for clients wanting long-term help&lt;/li&gt;
&lt;li&gt;Need to be very comfortable with live video&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  6. Guru
&lt;/h2&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%2Fiqjz6l0uanujlovrkve9.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%2Fiqjz6l0uanujlovrkve9.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.guru.com/" rel="noopener noreferrer"&gt;Guru&lt;/a&gt; is yet another large platform that has opportunities for people with a whole range of skills. It is highly flexible, you can choose jobs by location, category, or job type (hourly or fixed). Guru’s flexibility can cause confusion, though. For example, Guru charges each seller a commission on their rate, a standard practice for freelancer platforms — plus a nominal handling fee of 2.9%.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Great ease-of-use&lt;/li&gt;
&lt;li&gt;It’s membership-based which tends to encourage reliability&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The pricing structure can be confusing&lt;/li&gt;
&lt;li&gt;Not as popular as some of the larger platforms&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  7. People Per Hour
&lt;/h2&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%2Fhbsv6novask5w7im91r4.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%2Fhbsv6novask5w7im91r4.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.peopleperhour.com/" rel="noopener noreferrer"&gt;PeoplePerHour&lt;/a&gt; is a UK-based platform that streamlines the typical freelancing process by consolidating all the communication, payments, and job management. You can send up to 15 proposals to clients for free before needing to sign up for a paid plan — this is a great way to try out the platform! Many projects are available for developers, designers, SEO specialists and technical writers.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You can try out the platform for free!&lt;/li&gt;
&lt;li&gt;It comes with an app for added convenience&lt;/li&gt;
&lt;li&gt;Invoicing is automatic&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Customer support will almost always take a buyer’s side&lt;/li&gt;
&lt;li&gt;Poor customer support if there are technical problems or payment issues&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  8. Arc
&lt;/h2&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%2Fvqd3g16r8ioow0is51oi.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%2Fvqd3g16r8ioow0is51oi.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://arc.dev/" rel="noopener noreferrer"&gt;Arc&lt;/a&gt; is a great platform for programmers and web designers looking to work from home. There is a pretty strict vetting process, which is great if you’re a more skilled professional looking to stand out from the crowd. If you’re just starting out, it would be better to accumulate some skills and experience before using Arc. &lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Huge community &lt;/li&gt;
&lt;li&gt;Trusted by leading startups and tech companies&lt;/li&gt;
&lt;li&gt;Very smooth onboarding process and easy to use platform&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The vetting process is quite tough!&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  9. Scalable Path
&lt;/h2&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%2F5htkwb20l114rwp5o0wi.jpeg" 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%2F5htkwb20l114rwp5o0wi.jpeg" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.scalablepath.com/" rel="noopener noreferrer"&gt;Scalable Path&lt;/a&gt; is a freelance marketplace that specializes in helping businesses scale their IT teams by connecting businesses with top freelance developers. The minimum project size is 150 hours or USD7,500.00 (approximately one developer for one month). If a project is smaller than that, they advise employers against signing up for their sourcing and vetting services.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Guaranteed large projects that pay well&lt;/li&gt;
&lt;li&gt;Excellent if you're looking for long-term opportunities&lt;/li&gt;
&lt;li&gt;Great for experienced developers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Only for developers&lt;/li&gt;
&lt;li&gt;Not ideal for beginner&lt;a href="https://www.storetasker.com/" rel="noopener noreferrer"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  10. Storetasker
&lt;/h2&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%2Fecame0jh7r7bbstmhif6.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%2Fecame0jh7r7bbstmhif6.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.storetasker.com/" rel="noopener noreferrer"&gt;Storetasker&lt;/a&gt; is the #1 marketplace for Shopify developers looking to work with eCommerce brands. If you’re a Shopify specialist, Storetasker is ideal if you're looking to work exclusively on the platform. The application process is straightforward you’ll typically be up and running within 2 days of applying.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ideal if you have Shopify development experience &lt;/li&gt;
&lt;li&gt;A very nice website with excellent UI&lt;/li&gt;
&lt;li&gt;Great customer service&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Only for Shopify developers&lt;/li&gt;
&lt;li&gt;No real vetting process making for high competition&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  11. 99designs
&lt;/h2&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%2F7s8omjdc90m1ujth6gbg.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%2F7s8omjdc90m1ujth6gbg.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://99designs.com/designers" rel="noopener noreferrer"&gt;99designs&lt;/a&gt; is the world’s largest on-demand design marketplace, clients are often looking to have logos created, web pages designed, or may even be looking for custom illustrations.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Great for beginners looking for experience&lt;/li&gt;
&lt;li&gt;Good customer support&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Need to put in a lot of time to get regular work&lt;/li&gt;
&lt;li&gt;Very competitive &lt;/li&gt;
&lt;li&gt;Difficult to communicate directly with the client within the platform&lt;a href="https://speedlancer.com/" rel="noopener noreferrer"&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  12. Speedlancer
&lt;/h2&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%2F96xccs523j4spcmrjrb1.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%2F96xccs523j4spcmrjrb1.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://speedlancer.com/" rel="noopener noreferrer"&gt;Speedlancer&lt;/a&gt; is a unique platform in that it uses the “power of the crowd” to deliver projects quickly. Speedlancer specializes in tasks that can be fulfilled within 4 hours. However, tasks that require more than 4 hours to complete are also catered for with “bundles”. The most popular tasks are web design, development and writing.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Recommended pricing packages based on the task&lt;/li&gt;
&lt;li&gt;Great if you're looking for quick tasks on the side&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Poor ratings can result in your account being blocked&lt;/li&gt;
&lt;li&gt;Not useful if you want larger projects&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  13. Truelancer
&lt;/h2&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%2Fdsvgxapm8b4qvymy2zop.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%2Fdsvgxapm8b4qvymy2zop.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.truelancer.com/" rel="noopener noreferrer"&gt;Truelancer&lt;/a&gt; has jobs from web and app development, to design, sales, SEO work and more! Their platform is quick, trustworthy, and you have the flexibility to build up an ongoing working relationship with clients.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A great place for beginners looking to secure their first gig!&lt;/li&gt;
&lt;li&gt;Good support team&lt;/li&gt;
&lt;li&gt;Large range of projects&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Another highly competitive platform&lt;/li&gt;
&lt;li&gt;Need to put in a decent amount of work to secure projects&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  14. Crossover
&lt;/h2&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%2Fbv4cprhu1u0c6p5xrqpb.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%2Fbv4cprhu1u0c6p5xrqpb.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.crossover.com/pages/testimonials" rel="noopener noreferrer"&gt;Crossover&lt;/a&gt; connects talent from around the globe with companies that are looking to hire top-quality freelancers. With this platform, you’ll work a 40 hour week on a contract basis. Crossover is not a marketplace for small jobs, but rather for long-term positions.&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Great if you want the peace of mind of full-time remote work&lt;/li&gt;
&lt;li&gt;A reliable source of income&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Earnings are low for the time invested&lt;/li&gt;
&lt;li&gt;Less flexibility&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  15. Adeva
&lt;/h2&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%2F6sg8c3qq7f52y7e8o1ae.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%2F6sg8c3qq7f52y7e8o1ae.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://adevait.com/" rel="noopener noreferrer"&gt;Adeva&lt;/a&gt; ensures all freelancers have gone through a rigorous screening process, including not only technical skills but aptitude and personality too. If you have solid software development experience, Adeva will likely be a great option!&lt;/p&gt;

&lt;p&gt;✅ &lt;strong&gt;Pros&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Top-tier clients&lt;/li&gt;
&lt;li&gt;Passing the interview process gives you access to a more exclusive platform (and higher-paying clients)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;❌ &lt;strong&gt;Cons&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Not ideal for beginners&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;And there you go! There really are a ton of options when it comes to freelance platforms, and you can pick and choose depending on your skill level.&lt;/p&gt;

&lt;p&gt;Beginners would be well suited to Upwork, Freelancer or Fiverr — as they are open to everyone and have an endless amount of projects for every skill level. If you’re more experienced, platforms such as Arc.dev, Storetasker (if you specialize in Shopify), or Adeva would be ideal, as clients will likely pay a higher price for your work, knowing that each of these platforms has a strict vetting process for freelancers.&lt;/p&gt;

&lt;p&gt;And there is nothing stopping you from having a presence on multiple platforms! It will give you the most exposure, and once you’ve created a stellar profile on one platform, it’s not difficult to port it across to the others.&lt;/p&gt;

&lt;p&gt;In time, you’ll find the platform/s that work best for you 👍&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&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%2Fq8jx3gvzvjazn8z1mbjm.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%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>freelance</category>
      <category>design</category>
      <category>beginners</category>
    </item>
    <item>
      <title>JavaScript Fundamentals: Data Types</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Tue, 30 Jan 2024 15:00:05 +0000</pubDate>
      <link>https://dev.to/timothyrobards/javascript-fundamentals-data-types-4e5f</link>
      <guid>https://dev.to/timothyrobards/javascript-fundamentals-data-types-4e5f</guid>
      <description>&lt;p&gt;Let’s take a look at data type fundamentals in JavaScript! &lt;/p&gt;

&lt;p&gt;By the end of the article, you’ll have an increased understanding of working with many of the major data types. Which is a fundamental skill to pickup, as you move forward with JavaScript.&lt;/p&gt;




&lt;blockquote&gt;
&lt;p&gt;🤓 Want to stay up to date with web dev?&lt;br&gt;
🚀 Want the latest news delivered right to your inbox?&lt;br&gt;
🧑‍💻 Join a growing community of designers &amp;amp; developers!&lt;br&gt;
🎉 &lt;strong&gt;Subscribe to my newsletter → &lt;a href="https://easeout.eo.page"&gt;here&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  What are Data Types?
&lt;/h2&gt;

&lt;p&gt;Data types are classifications of specific types of data. We have numbers, Booleans (true or false), strings (character sequences enclosed in quotes &lt;code&gt;‘’&lt;/code&gt; or &lt;code&gt;“”&lt;/code&gt;) and more complex data types known as arrays and objects (we’ll look at these a bit later).&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;           &lt;span class="c1"&gt;// a is a number&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Avocado&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;   &lt;span class="c1"&gt;// a is a string&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;        &lt;span class="c1"&gt;// a is a Boolean&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;               &lt;span class="c1"&gt;// a is undefined&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For example, &lt;code&gt;a&lt;/code&gt;, has been defined as a variable using the &lt;code&gt;let&lt;/code&gt; keyword. We can assign any &lt;em&gt;data&lt;/em&gt; type to it, or even just initialize it by leaving it blank.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why Does it matter?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;When storing data in a variable, it’s important that we know its type, as that determines what we can do with it! For instance, you can add numbers &lt;code&gt;1 + 1 = 2&lt;/code&gt;, and that’s fine. However, if you attempt to add numbers when they have the data type of string &lt;code&gt;“1” + “1” = 11&lt;/code&gt; Your result will be 1 and 1, not the sum equaling 2 as you may have expected. Let's now take a look at each type in detail.&lt;/p&gt;

&lt;h3&gt;
  
  
  Numbers
&lt;/h3&gt;

&lt;p&gt;Numbers in JavaScript can be written with &lt;em&gt;or&lt;/em&gt; without decimals, such as:&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;b&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;1.1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;And they can be abbreviated using the &lt;code&gt;e&lt;/code&gt; exponent, for example:&lt;/em&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;let&lt;/span&gt; &lt;span class="nx"&gt;million&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1000000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// or..&lt;/span&gt;

&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;million&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="nx"&gt;e6&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The 6 is the amount of 0’s, which in this case equals one million.&lt;/p&gt;

&lt;p&gt;There are a few special values that we often encounter when working with numbers, &lt;code&gt;Infinity&lt;/code&gt;, &lt;code&gt;-Infinity&lt;/code&gt; and &lt;code&gt;NaN.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;If you attempt to divide a number by 0, such as:&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="mi"&gt;3&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;    &lt;span class="c1"&gt;// Infinity&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The result will be Infinity. As the JavaScript computes the result outside its largest possible number of &lt;code&gt;9007199254740992&lt;/code&gt;. The opposite would yield:&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="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;   &lt;span class="c1"&gt;// -Infinity&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The value of &lt;code&gt;NaN&lt;/code&gt; represents ‘Not a Number’, meaning the value isn’t considered a number. This would generate in illegal expressions, such as:&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Greg&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;     &lt;span class="c1"&gt;// a will be NaN&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As of course you can’t divide a number by a string!&lt;/p&gt;

&lt;p&gt;However, JavaScript is smart enough to convert your data type in some cases, such as:&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;2&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;         &lt;span class="c1"&gt;// a will be 50&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;JavaScript will use type coercion to consider your “2” string to be a number in this case.&lt;/p&gt;

&lt;h3&gt;
  
  
  Strings
&lt;/h3&gt;

&lt;p&gt;As mentioned earlier, strings are sequences of characters that exist within either single or double quotes:&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;let&lt;/span&gt; &lt;span class="nx"&gt;foodChoice&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Crunchy cheddar jalapeno cheetos&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;foodChoice&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Crunchy cheddar jalapeno cheetos&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Strings aren’t limited to letters either, numbers and symbols are also acceptable. It’s the quotes that define our string data type.&lt;/p&gt;

&lt;p&gt;It really comes down to personal preference as to whether you use single or double quotes, consistency is what’s most important within your code!&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;let&lt;/span&gt; &lt;span class="nx"&gt;eater&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="err"&gt;“&lt;/span&gt;&lt;span class="nx"&gt;Bruce&lt;/span&gt;&lt;span class="err"&gt;”&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;foodChoice&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Crunchy cheddar jalapeno cheetos&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;eater&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt; loves &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;foodChoice&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;!&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;// Bruce loves Crunchy cheddar jalapeno cheetos!&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Booleans
&lt;/h3&gt;

&lt;p&gt;We use the keywords &lt;code&gt;true&lt;/code&gt; and &lt;code&gt;false&lt;/code&gt; to set variables as Boolean data type.&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;b&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Booleans are especially useful when performing mathematical operations, in determining whether an expression is true or false, such as:&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="mi"&gt;10&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;     &lt;span class="c1"&gt;// true, 10 is greater than 5&lt;/span&gt;
&lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;     &lt;span class="c1"&gt;// false, 5 is not greater than 10&lt;/span&gt;
&lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;     &lt;span class="c1"&gt;// true, 5 is less than 10&lt;/span&gt;
&lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;      &lt;span class="c1"&gt;// true, 5 equals 5&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If we assign our expression to a variable, such as:&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;   &lt;span class="c1"&gt;// true&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our variable &lt;code&gt;a&lt;/code&gt; will of course, hold the value of true.&lt;/p&gt;

&lt;p&gt;Booleans are used within programs when we need to perform operations based on the evaluation of truth or falsehood. For example, do the received login credentials evaluate to true? Grant access ✔️. Or are they false? Deny access ❌.&lt;/p&gt;

&lt;h3&gt;
  
  
  Arrays
&lt;/h3&gt;

&lt;p&gt;An array is a slightly more complex data type, however they are really quite simple to grasp! An array is a way to have multiple values held by a single variable. For example:&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;let&lt;/span&gt; &lt;span class="nx"&gt;colors&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;red&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;green&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;blue&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;yellow&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;An array is defined by using square brackets &lt;code&gt;[]&lt;/code&gt; as in the above example. We’ve assigned an array to the variable &lt;code&gt;colors&lt;/code&gt;, contained within are our &lt;strong&gt;elements&lt;/strong&gt; of red, green, blue and yellow.&lt;/p&gt;

&lt;p&gt;A call to our &lt;code&gt;colors&lt;/code&gt; variable will output our entire array of &lt;code&gt;[“red”, “green”, “blue”, “yellow”]&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;The true power of arrays is that their contents can be iterated, we can call out a single item within the array variable. To do this we use an index number, inside of square brackets:&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;colors&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;     &lt;span class="c1"&gt;// red&lt;/span&gt;
&lt;span class="nx"&gt;colors&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;     &lt;span class="c1"&gt;// green&lt;/span&gt;
&lt;span class="nx"&gt;colors&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;     &lt;span class="c1"&gt;// blue&lt;/span&gt;
&lt;span class="nx"&gt;colors&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;     &lt;span class="c1"&gt;// yellow&lt;/span&gt;
&lt;span class="nx"&gt;colors&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;     &lt;span class="c1"&gt;// undefined&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; Our first array element always has the index position of 0. So remember to start counting from 0 instead of 1!&lt;/p&gt;

&lt;p&gt;Arrays have a large amount of flexibility, they can have elements added, removed and changed. Let’s now take a look at our final data type: objects!&lt;/p&gt;

&lt;h3&gt;
  
  
  Objects
&lt;/h3&gt;

&lt;p&gt;The object data type is typically used for holding large amounts of related data. Object data values are stored in key/value pairs, the pairs make for a logical way to store and access our data, using curly braces &lt;code&gt;{}&lt;/code&gt;, for example:&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;let&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="na"&gt;firstName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Jane&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;lastName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;age&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="mi"&gt;34&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;location&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Vancouver&lt;/span&gt;&lt;span class="dl"&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 clarity we’d write this out over multiple lines:&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;let&lt;/span&gt; &lt;span class="nx"&gt;user&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;firstName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Jane&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;lastName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;age&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;34&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;location&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Vancouver&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our above example contains four properties &lt;code&gt;firstName&lt;/code&gt;, &lt;code&gt;lastName&lt;/code&gt;, &lt;code&gt;age&lt;/code&gt;, and &lt;code&gt;location&lt;/code&gt;. Our properties can be of any data type, which are accessed using &lt;em&gt;objectName.property&lt;/em&gt; as follows:&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;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;firstName&lt;/span&gt;     &lt;span class="c1"&gt;// Jane&lt;/span&gt;
&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;lastName&lt;/span&gt;      &lt;span class="c1"&gt;// Doe&lt;/span&gt;
&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;age&lt;/span&gt;           &lt;span class="c1"&gt;// 34&lt;/span&gt;
&lt;span class="nx"&gt;user&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;location&lt;/span&gt;      &lt;span class="c1"&gt;// Vancouver&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Understanding how we classify data types is a fundamental skill to posses when moving forward with JavaScript. In this article, we looked at and what distinguishes each type. &lt;/p&gt;

&lt;p&gt;Stay tuned for my next post, where we'll expand upon this knowledge by learning how to perform data type conversions.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>JavaScript Fundamentals: Syntax &amp; Structure</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Mon, 26 Dec 2022 03:58:11 +0000</pubDate>
      <link>https://dev.to/timothyrobards/javascript-fundamentals-syntax-structure-544i</link>
      <guid>https://dev.to/timothyrobards/javascript-fundamentals-syntax-structure-544i</guid>
      <description>&lt;p&gt;As with any language, programming languages are defined by sets of rules. The rules (or syntax) are what we follow when we write our code, which form the logical structure of our programs.&lt;/p&gt;

&lt;p&gt;This article marks the beginning of a series I’ll be writing on learning the JavaScript fundamentals. Be sure to check back often!&lt;/p&gt;

&lt;p&gt;Let’s dive right in with the building blocks of JavaScript. We’ll be looking at values (literals &amp;amp; variables), camel casing, unicode, semi colons, indentation, white spacing, commenting, case sensitivity, keywords, operators and expressions! 😅&lt;/p&gt;

&lt;p&gt;By taking the time to learn the fundamentals, we’ll be well on our way toward building more functional and readable code!&lt;/p&gt;

&lt;h2&gt;
  
  
  JavaScript Values
&lt;/h2&gt;

&lt;p&gt;In JavaScript there are two types of values: Fixed values (or &lt;strong&gt;literals&lt;/strong&gt;) and Variable values (&lt;strong&gt;variables&lt;/strong&gt;).&lt;/p&gt;

&lt;h3&gt;
  
  
  Literals
&lt;/h3&gt;

&lt;p&gt;Literals are defined as values that are written in our code, such as numbers, strings, booleans (true or false), as well as object and array literals (don’t worry too much about these just yet). Some examples include:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;10          // A number (can be a decimal eg. 10.5)
'Boat'      // A string (can be in double "" or single '' quotes)
true        // A boolean (true or false)
['a', 'b']                           // An array
{color: 'blue', shape: 'Circle'}     // An object
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Note: I’ll be looking at data types in detail in the next article in this series, stay tuned!&lt;/em&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Variables
&lt;/h3&gt;

&lt;p&gt;Variables are named values which store data. In JavaScript we declare our variables with the &lt;code&gt;var&lt;/code&gt;, &lt;code&gt;let&lt;/code&gt; or &lt;code&gt;const&lt;/code&gt; keywords, and we assign values with the equal sign &lt;code&gt;=&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;For example, &lt;code&gt;key&lt;/code&gt; is defined as a variable. Which is assigned the value &lt;code&gt;abc123&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;let key;
key = abc123;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When to use &lt;code&gt;var&lt;/code&gt;? Don’t. It really should only be used when working with legacy code. Its the old pre-ES6 syntax.&lt;/p&gt;

&lt;p&gt;When to use &lt;code&gt;let&lt;/code&gt;? Use it if your variable needs to be updated within the program (it can be reassigned).&lt;/p&gt;

&lt;p&gt;When to use &lt;code&gt;const&lt;/code&gt;? Use it if your variable holds a constant value. It must be assigned at the time of declaration and it cannot be reassigned.&lt;/p&gt;

&lt;h2&gt;
  
  
  Camel Case
&lt;/h2&gt;

&lt;p&gt;What if our variable name consists of more than one word? For example, how would we declare a variable we wish to name “first name”?&lt;/p&gt;

&lt;p&gt;Could we use &lt;strong&gt;hyphens?&lt;/strong&gt; e.g. &lt;code&gt;first-name&lt;/code&gt;Nope, &lt;code&gt;-&lt;/code&gt;’s are reserved for subtractions in JavaScript.&lt;/p&gt;

&lt;p&gt;What about &lt;strong&gt;underscores?&lt;/strong&gt; e.g. &lt;code&gt;first_name&lt;/code&gt; We could, but it has a tendency to make our code look messy and confusing.&lt;/p&gt;

&lt;p&gt;The solution? &lt;strong&gt;camel case&lt;/strong&gt;! e.g. &lt;code&gt;firstName&lt;/code&gt;. The first word is lower-case, the first letter of any subsequent words are upper-case. This is the convention within the community.&lt;/p&gt;

&lt;p&gt;Note: It’s quite acceptable however, to name your &lt;code&gt;const&lt;/code&gt; variables in upper-case with underscores e.g. &lt;code&gt;const DEFAULT_PLAYBACK_SPEED = 1;&lt;/code&gt; This would make it clear to others that the value is fixed. Otherwise just stick with camelCase!&lt;/p&gt;

&lt;h2&gt;
  
  
  Unicode
&lt;/h2&gt;

&lt;p&gt;JavaScript uses the unicode character set. Unicode covers just about all of the characters, punctuations, and symbols that there are! Check out the &lt;a href="https://unicode-table.com/" rel="noopener noreferrer"&gt;complete reference&lt;/a&gt;. This is great as we can write our names in any language, and we could even use &lt;a href="https://emojipedia.org/" rel="noopener noreferrer"&gt;emojis&lt;/a&gt; as variable names (because why not? 🤷🏻‍♂️).&lt;/p&gt;

&lt;h2&gt;
  
  
  Semicolons
&lt;/h2&gt;

&lt;p&gt;JavaScript programs are made up of a number of instructions known as statements. Such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// These are all examples of JavaScript statements:

let a = 1000;

a = b + c;

const time = Date.now();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;JavaScript statements often end in a semicolon &lt;code&gt;;&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;However, &lt;strong&gt;semicolons aren’t always mandatory!&lt;/strong&gt; JavaScript does not have any issues if you don’t use them.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Still perfectly valid!

let a = 1000

a = b + c

const time = Date.now()
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There are however, some situations where they are mandatory. For instance when we use a &lt;code&gt;for&lt;/code&gt; loop, like so:&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="k"&gt;for &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
  &lt;span class="c1"&gt;// code to execute&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When using a block statement however, semicolons are not to be included after the curly braces, for example:&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="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Samantha&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="c1"&gt;// code&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;                           &lt;span class="c1"&gt;// &amp;lt;- no ';'&lt;/span&gt;
&lt;span class="c1"&gt;//or,&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;people&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// code&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;                           &lt;span class="c1"&gt;// &amp;lt;- no ';'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If we’re using an object however, such as:&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;person&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;firstName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Samantha&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;lastName&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;age&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;eyeColor&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;blue&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;                          &lt;span class="c1"&gt;// the ';' is mandatory&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then our &lt;code&gt;;&lt;/code&gt;’s are required!&lt;/p&gt;

&lt;p&gt;Over time you’ll start to memorize where semicolons can and can’t be used. Until then it’s wise to use them at the end of all statements (with the exception of block statements!)&lt;/p&gt;

&lt;p&gt;Plus it really is a common convention is to use them regardless, it’s considered good practice as its reduces the probability of errors.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note: Once you really get going with JavaScript, start using a linter such as &lt;a href="https://eslint.org/" rel="noopener noreferrer"&gt;ESLint&lt;/a&gt;. It’ll automatically find syntax errors in your code and make life much easier!&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Indentation
&lt;/h2&gt;

&lt;p&gt;In theory we could write an entire JavaScript program on one line. However this would be just about impossible to read and maintain. Which is why we use lines and indentation. Lets use a conditional statement as an example:&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="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;loginSuccessful&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// code to run if true&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// code to run if false&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here we can see that any code inside a block is indented. In this case its our comment code &lt;code&gt;// code to run if true&lt;/code&gt; and then &lt;code&gt;// code to run if false.&lt;/code&gt; You can choose to indent your lines with either a few spaces (2 or 4 are common) or a tab. It’s entirely your choice, the main thing is to be consistent!&lt;/p&gt;

&lt;p&gt;If we are nesting our code, we’d indent further like so:&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="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;loginAttempts&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="p"&gt;){&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;loginAttempts&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;){&lt;/span&gt;
    &lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;&amp;lt; 3&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="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;between 3 and 5&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;span class="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;loginAttempts&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;){&lt;/span&gt;
    &lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;&amp;gt; 10&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="k"&gt;else&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;between 5 and 10&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;By applying indentation you’ll have much cleaner, more maintainable and easier to read code!&lt;/p&gt;

&lt;h2&gt;
  
  
  White Space
&lt;/h2&gt;

&lt;p&gt;JavaScript only requires one space between keywords, names and identifiers, otherwise any white space is completely ignored. This means that as far as the language is concerned, there is no difference between the following statements:&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;visitedCities&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Melbourne, &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="o"&gt;+&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Montreal, &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="o"&gt;+&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Marrakech&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;visitedCities&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Melbourne, &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Montreal, &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Marrakech&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I’m sure you’ll find the second line much more readable. And another example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;let x=1*y;       
let x = 1 * y;  
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Again, the second line is much easier to read and debug! So feel free to space out your code in a way that makes sense! For that reason, this is also an acceptable use of white space:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const cityName         = "Melbourne";
const cityPopulation   = 5000001;
const cityAirport      = "MEL";
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Commenting
&lt;/h2&gt;

&lt;p&gt;A comment is un-executable code. They’re useful for providing an explanation of some code within a program. And also to ‘comment out’ a section of code to prevent execution — often used when testing an alternative piece of code.&lt;/p&gt;

&lt;p&gt;There are two types of comments in JavaScript:&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="c1"&gt;// Comment goes here&lt;/span&gt;

&lt;span class="cm"&gt;/* Comment goes here */&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The first syntax is a single line comment. The comment goes to the right of the &lt;code&gt;//&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;The second a multi-line comment. The comment goes in between the asterisks &lt;code&gt;/* here */&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;A longer multi-line comment:&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="cm"&gt;/* This is 
a comment spanning
multiple lines */&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Identifiers
&lt;/h2&gt;

&lt;p&gt;In JavaScript, the name of a variable, function, or property is known as an identifier. Identifiers may consist of letters, numbers, &lt;code&gt;$&lt;/code&gt; and &lt;code&gt;_&lt;/code&gt;. No other symbols are permitted, and they cannot begin with a number.&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="c1"&gt;// Valid 😀&lt;/span&gt;

&lt;span class="nx"&gt;Name&lt;/span&gt;
&lt;span class="nx"&gt;name&lt;/span&gt;
&lt;span class="nx"&gt;NAME&lt;/span&gt;
&lt;span class="nx"&gt;_name&lt;/span&gt;
&lt;span class="nx"&gt;Name1&lt;/span&gt;
&lt;span class="nx"&gt;$name&lt;/span&gt;

&lt;span class="c1"&gt;// Invalid 😢&lt;/span&gt;

&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;
&lt;span class="nx"&gt;n&lt;/span&gt;&lt;span class="p"&gt;@&lt;/span&gt;&lt;span class="nd"&gt;me&lt;/span&gt;
&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Case Sensitivity
&lt;/h2&gt;

&lt;p&gt;JavaScript is case sensitive! An identifier named &lt;code&gt;test&lt;/code&gt; is different from &lt;code&gt;Test&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;The following will throw an error:&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;function&lt;/span&gt; &lt;span class="nf"&gt;test&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;alert&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;This is a test!&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="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;showAlert&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;Test&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;                     &lt;span class="c1"&gt;// error! test(); is correct&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In order to ensure that our code is readable, it’s best to try to vary our names, so no identifiers are found looking too similar.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reserved Words
&lt;/h2&gt;

&lt;p&gt;There are a number of words within JavaScript that may not be used as identifiers. Those words are reserved by the language, as they have built-in functionality. Such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;break, do, instanceof, typeof, case, else, new, var, catch, finally, return, void, continue, for, switch, while, debugger, function, this, with, default, if, throw, delete, in, try, class, enum, extends, super, const, export, import.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;See the full &lt;a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Lexical_grammar#Reserved_keywords_as_of_ECMAScript_2015" rel="noopener noreferrer"&gt;list of reserved keywords&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;You certainly don’t need to commit these words to memory! If you get any strange syntax errors pointing to a variable, you can check the list and change the name.&lt;/p&gt;

&lt;h2&gt;
  
  
  JavaScript Operators
&lt;/h2&gt;

&lt;p&gt;Arithmetical operators &lt;code&gt;+ -&lt;/code&gt; &lt;code&gt;*&lt;/code&gt; and &lt;code&gt;/&lt;/code&gt; are primarily used when performing calculations within JavaScript, such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;(2 + 2) * 100
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The assignment operator &lt;code&gt;=&lt;/code&gt; is used to assign values to our variables:&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;let&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;b&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;c&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;b&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;c&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  JavaScript Expressions
&lt;/h2&gt;

&lt;p&gt;An expression is when we combine values, variables and operators to compute a new value (known as a evaluation). Such as:&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="mi"&gt;10&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;    &lt;span class="c1"&gt;// Evaluates to 100&lt;/span&gt;

&lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="nx"&gt;x&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;
&lt;span class="nx"&gt;x&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;     &lt;span class="c1"&gt;// Evaluates to 50&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;firstName&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Samantha&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;lastName&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="nx"&gt;firstName&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt; &lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;lastName&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;    &lt;span class="c1"&gt;// Evaluates to: Samantha Doe&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;And there we go! This article aimed to provide a general overview of the basic syntax and structure of JavaScript. We’ve looked at many of the common conventions, however, remember you can be somewhat flexible — especially when working in collaborative environments with their own particular standards.&lt;/p&gt;

&lt;p&gt;Syntax and structuring both have an important role the play for both the functionality of our programs as well as for code readability and maintainability.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.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%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.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%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>ai</category>
      <category>startup</category>
    </item>
    <item>
      <title>React: Installation &amp; Setup</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Tue, 18 Oct 2022 02:07:51 +0000</pubDate>
      <link>https://dev.to/timothyrobards/react-installation-setup-51c9</link>
      <guid>https://dev.to/timothyrobards/react-installation-setup-51c9</guid>
      <description>&lt;p&gt;React is currently the most popular JavaScript library for building UIs —and that trend looks set to continue for the foreseeable future. In this article, we’re going to focus on the ways we can setup React, quickly and painlessly. So we can dive right into coding!&lt;/p&gt;

&lt;h2&gt;
  
  
  Why React?
&lt;/h2&gt;

&lt;p&gt;For the uninitiated, React allows us to build extremely fast web apps through the use of the Virtual DOM — it essentially renders only what it needs to. Providing a lightweight alternative to the traditional way of working directly with the &lt;a href="https://developer.mozilla.org/en-US/docs/Web/API/Document_Object_Model/Introduction"&gt;DOM&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;React also promotes a component based workflow, meaning your UI is essentially just a collection of components. This makes for a fantastic building experience! As you’ll build with modularity, your code will be in neat self-contained chunks. And it’s also very useful when working in teams, individuals can work on parts of a project, while still working collectively toward project completion.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installation &amp;amp; Setup
&lt;/h2&gt;

&lt;p&gt;There are a number of ways to get up and running with React. Firstly, we’ll take a peek at CodeSandbox and CodePen. If you want to instantly start playing around with code, this is a nice way to go!&lt;/p&gt;

&lt;p&gt;We’ll then focus on spinning up a React project with Create React App — which gives you an awesome starting point for your projects, without the need to spend time setting up a build environment.&lt;/p&gt;

&lt;h2&gt;
  
  
  React in CodeSandbox
&lt;/h2&gt;

&lt;p&gt;CodeSandBox is an online code editor which you can use to get a React project up and running in no time at all.&lt;/p&gt;

&lt;p&gt;Go to &lt;a href="https://codesandbox.io/s"&gt;https://codesandbox.io/s&lt;/a&gt; and click &lt;strong&gt;React&lt;/strong&gt;.&lt;/p&gt;

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

&lt;p&gt;Instantly, you’ll be in a React environment that has been configured with the &lt;em&gt;create-react-app&lt;/em&gt; structure. We’ll look at this structure further on in the article! If you want to start coding without setting up a local install, this is a great way to go! Tasks such as transpiling, bundling and dependency management are all automated, and you can easily share the link of anything you’ve been working on!&lt;/p&gt;

&lt;h2&gt;
  
  
  React in CodePen
&lt;/h2&gt;

&lt;p&gt;An alternative to CodeSandBox is &lt;a href="https://codepen.io/"&gt;CodePen&lt;/a&gt;. Many developers use CodePen to showcase their work by creating “pens” for quick code demos, or “projects” for when multiple files are involved. CodeSandbox is definitely more feature rich for working with React, however CodePen is also a fine solution.&lt;/p&gt;

&lt;p&gt;I’ve created a CodePen React starter here:&lt;/p&gt;

&lt;p&gt;See the Pen &lt;a href="https://codepen.io/trobes/pen/exzrrm"&gt;React Sandbox&lt;/a&gt; by Timothy Robards&lt;br&gt;
  (&lt;a href="https://codepen.io/trobes"&gt;@trobes&lt;/a&gt;) on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Create React App
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Create React App&lt;/em&gt; is a tool (built by developers at Facebook) that’ll give you a massive head start when building React apps. It handles all of the configuration, so you don’t need to know any Babel or Webpack. You just run the initial install &amp;amp; you’ll be up in a local dev environment, in no time!&lt;/p&gt;

&lt;h3&gt;
  
  
  Installing with Create React App
&lt;/h3&gt;

&lt;p&gt;All we need to do is open up our terminal, and run the following:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npx create-react-app &amp;lt;app-name&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Where &lt;code&gt;&amp;lt;app-name&amp;gt;&lt;/code&gt; is of course, the name of your app!&lt;/p&gt;

&lt;p&gt;We use &lt;code&gt;npx&lt;/code&gt; as it will download and run Node.js commands without installing them. If you don’t have Node installed, you can &lt;a href="https://nodejs.org/en/download/"&gt;download it here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;So go ahead and run the above command to begin the install! Give it whatever name you like..&lt;/p&gt;

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

&lt;p&gt;The install might take a few minutes to complete. Right now it’s installing all of the dependencies required to build your project. And it’s also generating your initial project structure.&lt;/p&gt;

&lt;p&gt;☕️…&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuuioamjovqb5fqiy20fs.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuuioamjovqb5fqiy20fs.png" alt="React Installation Options" width="630" height="453"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Success! Now you can open up your project folder &amp;amp; check out the created file structure.&lt;/p&gt;

&lt;p&gt;Additionally, a Git repository has been created for you. And several commands have been added into the &lt;code&gt;package.json&lt;/code&gt; file:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;npm start&lt;/code&gt; starts the development server, including auto page reloads for when you make edits&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;npm run build&lt;/code&gt; bundles the app into static files for production into a &lt;code&gt;build&lt;/code&gt; folder&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;npm test&lt;/code&gt; starts the test runner using Jest&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;npm run eject&lt;/code&gt; ejects your app out of the create-react-app setup, which lets you customize your project configuration&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Starting your Create React App
&lt;/h3&gt;

&lt;p&gt;Now lets start up our local server! From your app folder, run:&lt;br&gt;
&lt;/p&gt;

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

&lt;/div&gt;



&lt;p&gt;Your app will launch in the browser on &lt;code&gt;localhost:3000.&lt;/code&gt;&lt;/p&gt;

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

&lt;p&gt;And we’re done! Each time you start a new project with &lt;em&gt;create-react-app&lt;/em&gt;, you’ll have the latest version of React, React-DOM &amp;amp; React-Scripts. Lets now take a brief look at some of the features of &lt;em&gt;create-react-app&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Create-React-App features
&lt;/h2&gt;

&lt;p&gt;As you’ll see in the generated &lt;code&gt;package.json&lt;/code&gt;, there are a number of commands which are available for use in your apps — lets take a look at these now..&lt;/p&gt;

&lt;h3&gt;
  
  
  Building for Production
&lt;/h3&gt;

&lt;p&gt;When the times comes to move from development to production, you can do so by running &lt;code&gt;npm run build&lt;/code&gt;. A &lt;code&gt;build&lt;/code&gt; folder will generate containing all of the static files to be used on a production server.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;build&lt;/code&gt; command itself will transpile your React code into code that the browser understands (using Babel). It’ll also optimize your files for best performance, by bundling all of your JavaScript files into one single file, which will be minified to reduce load times.&lt;/p&gt;

&lt;h3&gt;
  
  
  Testing your app
&lt;/h3&gt;

&lt;p&gt;Included with &lt;em&gt;create-react-app&lt;/em&gt; is &lt;a href="https://jestjs.io/"&gt;JEST&lt;/a&gt;, which allows you to test your code by running &lt;code&gt;npm test&lt;/code&gt;. It’ll launch in a similar manner to &lt;code&gt;npm start&lt;/code&gt; in that it will re-run your tests, each time you make changes.&lt;/p&gt;

&lt;p&gt;If you haven’t yet run unit tests, you can safely file this away as a ‘nice to know’ for now. For those interested in testing components with Jest, all you need to do is either suffix your required files with &lt;code&gt;.spec.js&lt;/code&gt; or &lt;code&gt;.test.js&lt;/code&gt;, or place your test files inside of a &lt;code&gt;__tests__&lt;/code&gt; folder. Jest will run your tests for the files you specify.&lt;/p&gt;

&lt;h3&gt;
  
  
  Ejecting
&lt;/h3&gt;

&lt;p&gt;Whenever you create an app with &lt;em&gt;create-react-app&lt;/em&gt;, your build settings are not able to be altered, as they’ve been preconfigured in react-scripts. However, by running &lt;code&gt;npm run eject&lt;/code&gt;, you can gain full control of your &lt;em&gt;create-react-app&lt;/em&gt; configuration.&lt;/p&gt;

&lt;p&gt;The config will be copied into your apps directory in a new &lt;code&gt;config&lt;/code&gt; folder, and your scripts into a &lt;code&gt;scripts&lt;/code&gt; folder. You can then edit your Webpack, Babel and ESLint configurations to your hearts’ content.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; Running eject is permanent! Only do so if you’re ready to go it alone (you know what you’re doing!).&lt;/p&gt;

&lt;h3&gt;
  
  
  Error messages
&lt;/h3&gt;

&lt;p&gt;Another helpful feature included with &lt;em&gt;create-react-app&lt;/em&gt; are the built-in error messages that generate to both the console and browser window.&lt;/p&gt;

&lt;p&gt;Typos and syntax errors will throw a compilation error. And if you have a bunch of errors, you’ll get an overlay breaking down each, like so:&lt;/p&gt;

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

&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;And there we go! We’ve seen how to start playing around with React in CodeSandbox &amp;amp; CodePen. And we’ve looked at how to setup a local development environment with &lt;em&gt;create-react-app.&lt;/em&gt; You don’t need to spend any time installing dependencies or configuring a build process — you can jump right into coding!&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>programming</category>
      <category>react</category>
    </item>
    <item>
      <title>The GitHub Development Workflow</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Sun, 09 Oct 2022 14:33:26 +0000</pubDate>
      <link>https://dev.to/timothyrobards/the-github-development-workflow-512i</link>
      <guid>https://dev.to/timothyrobards/the-github-development-workflow-512i</guid>
      <description>&lt;p&gt;&lt;strong&gt;GitHub&lt;/strong&gt; is a code hosting platform for version control and collaboration. It’s designed around Git, a system for tracking changes in software code. It lets you and others work together on projects from anywhere. In this article, we’ll take a look at the key concepts of the GitHub development workflow. Including working with repositories, branches, forks, commits, pull requests, and merging. Let’s get started!&lt;/p&gt;

&lt;h2&gt;
  
  
  What is version control?
&lt;/h2&gt;

&lt;p&gt;Version control is a system that helps developers track and manage changes to a software projects' code. As projects grow, the need for version control becomes vital — especially in a collaborative project. We can work safely by using what's known as &lt;strong&gt;branching&lt;/strong&gt; and &lt;strong&gt;merging&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Branching&lt;/strong&gt; allows us to duplicate our source code (aka ‘the repository’), so we can safely make changes without affecting the entire project. Once the changes have been reviewed and approval is agreed upon, we &lt;strong&gt;merge&lt;/strong&gt; our branch into the master to update our official code. If any bugs are identified— we have the option to revert back to our original code, as our changes have been tracked.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is Git?
&lt;/h2&gt;

&lt;p&gt;Git and Github are not synonymous! Git is a specific open-source version control system created by &lt;a href="https://en.wikipedia.org/wiki/Linus_Torvalds"&gt;Linus Torvalds&lt;/a&gt; in 2005. It’s the program that actually tracks your changes, and ensures the entire code-base is available on each developer's computer. GitHub however, is simply hosting your repositories (as well as providing some additional functionality).&lt;/p&gt;

&lt;h2&gt;
  
  
  The Fundamentals
&lt;/h2&gt;

&lt;p&gt;Let’s get started! If you haven’t signed up for a GitHub account, go ahead and &lt;a href="https://github.com/join"&gt;sign up here&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Creating a Repository
&lt;/h3&gt;

&lt;p&gt;A GitHub &lt;strong&gt;repository&lt;/strong&gt; (or “repo”) can be thought of as the root folder for your project. It contains all your project files and gives you the ability to access each file's revision history. If you’re working in a team you can give other people access to your repository for project collaboration.&lt;/p&gt;

&lt;p&gt;Let's create our first repository! Make sure you're signed in to GitHub, then:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;In the upper-right corner, click the settings &lt;code&gt;+&lt;/code&gt; icon &amp;amp; then New repository&lt;/li&gt;
&lt;li&gt;Give your repository a name&lt;/li&gt;
&lt;li&gt;Add a description if you like&lt;/li&gt;
&lt;li&gt;Choose between creating a public or private repository (either is fine)&lt;/li&gt;
&lt;li&gt;Select Initialize this repository with a README (eg. “My first repo!”)&lt;/li&gt;
&lt;li&gt;Click Create repository!&lt;/li&gt;
&lt;li&gt;Add files to your repository ~&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;~ We’re only testing so it really doesn't matter what you add. Find an HTML file for example, and add it to your repository via the Upload files button.&lt;/p&gt;

&lt;h3&gt;
  
  
  Creating an Issue
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Issues&lt;/strong&gt; are how we track the tasks, enhancements, and bugs in our projects. They’re meant to be shared amongst your team to facilitate discussion for review as well as for managing task delegation. If you open an issue on a project managed by someone else, it’ll stay open until either you close it (for example if you figure out the problem) or if the repo owner closes it. When you create an issue, be sure to give a clear explanation of the task at hand. Let’s create an issue in our repository:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;In your repository, select the Issues tab&lt;/li&gt;
&lt;li&gt;Click the New Issue button&lt;/li&gt;
&lt;li&gt;Give your issue the title ‘Setup GitHub pages’&lt;/li&gt;
&lt;li&gt;Give a clear description e.g. ‘Need to setup GitHub Pages in this repository’&lt;/li&gt;
&lt;li&gt;Click Submit new issue&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Assigning an Issue
&lt;/h3&gt;

&lt;p&gt;We need to &lt;strong&gt;assign&lt;/strong&gt; issues so our team members know who’s job it is to handle the task!&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;On the right side of the screen, under the “Assignees” section, click the settings icon and select yourself&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Let’s resolve our first issue! We want to setup GitHub pages. You can read about GitHub Pages &lt;a href="https://pages.github.com/"&gt;here&lt;/a&gt;. But for now, our focus on completing the task:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Click on the Settings tab in your repository&lt;/li&gt;
&lt;li&gt;Scroll down to the “GitHub Pages” section&lt;/li&gt;
&lt;li&gt;From the “Source” drop-down, select master branch&lt;/li&gt;
&lt;li&gt;Click Save&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Closing an Issue
&lt;/h3&gt;

&lt;p&gt;Now you’ve completed the task — you can go ahead and close it! You can delete an issue on GitHub, however closing it tells your team members that the task has been completed. To close:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Open up your completed issue and click Close issue&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The GitHub Flow
&lt;/h2&gt;

&lt;p&gt;Now that we know how to work with issues, it’s time to look at the &lt;strong&gt;GitHub Flow&lt;/strong&gt;. Simply put its a workflow where we can experiment with new ideas safely, without the risk of compromising our project. This is primarily achieved through the use of &lt;strong&gt;branching&lt;/strong&gt;.&lt;/p&gt;

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

&lt;p&gt;By default, our project lives on the master branch — any changes to the master will update directly to our project (This can be dangerous is you haven’t properly reviewed your changes!).&lt;/p&gt;

&lt;p&gt;When we want to experiment with a new feature, or even fix an issue, we create a new &lt;strong&gt;branch&lt;/strong&gt; on the project. The branch will initially be a duplicate of your master, now when you make changes —they’ll reflect only on the branch.&lt;/p&gt;

&lt;p&gt;While working on changes, you’ll &lt;strong&gt;commit&lt;/strong&gt; the changes to your branch. When you’re satisfied that the changes are complete, its time to open a &lt;strong&gt;pull request.&lt;/strong&gt; From here your team will discuss and further refine the project changes. Once the changes have been approved, the branch will be &lt;strong&gt;merged&lt;/strong&gt; onto the &lt;strong&gt;master branch&lt;/strong&gt;. Let’s go through an example of this process now!&lt;/p&gt;

&lt;h3&gt;
  
  
  Creating a Branch
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Open your repository and click the Code tab&lt;/li&gt;
&lt;li&gt;Click &lt;code&gt;Branch: master&lt;/code&gt; in the drop-down&lt;/li&gt;
&lt;li&gt;In the field, enter a name for your branch (e.g. ‘development’)&lt;/li&gt;
&lt;li&gt;Click Create branch&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Now that you’ve created a branch, you can modify your project without changing the deployed &lt;code&gt;master&lt;/code&gt; branch.&lt;/p&gt;

&lt;p&gt;A note on forks — A &lt;strong&gt;fork&lt;/strong&gt; is different from a branch in that it allows you to &lt;strong&gt;clone&lt;/strong&gt; another repo in your own account. It essentially allows you to start a new project based on a previous project.&lt;/p&gt;

&lt;h3&gt;
  
  
  Committing a file
&lt;/h3&gt;

&lt;p&gt;Now we can safely work within our branch, let’s create a file and make our first commit.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Make an edit (anything! just add a simple comment to your code) to one of the files you had added to the repository earlier&lt;/li&gt;
&lt;li&gt;Give the commit a name and description&lt;/li&gt;
&lt;li&gt;Make sure your newly created (development) branch is selected&lt;/li&gt;
&lt;li&gt;Click Commit changes&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You’ve made your first commit! The next step is to share the changes with your team via a pull request.&lt;/p&gt;

&lt;h3&gt;
  
  
  Opening a Pull Request
&lt;/h3&gt;

&lt;p&gt;A pull request is where we share our proposed project changes with our team — with the intent of discussing &amp;amp; revising them before applying the changes to the &lt;code&gt;master&lt;/code&gt; branch.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open the Pull requests tab and click New pull request&lt;/li&gt;
&lt;li&gt;In the base: drop-down menu, ensure the master branch is selected&lt;/li&gt;
&lt;li&gt;In the compare: drop-down menu, select the development branch you created earlier&lt;/li&gt;
&lt;li&gt;Click Create pull request&lt;/li&gt;
&lt;li&gt;Now enter a title for your pull request, for example, “Add my changes”&lt;/li&gt;
&lt;li&gt;Add an accurate description of the changes you made&lt;/li&gt;
&lt;li&gt;Click Create pull request!&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Your team members now have the ability to discuss and review your proposed changes. Once everyone is happy and the changes are approved— it’s time to merge to &lt;code&gt;master.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Note: If you forked a repo and made changes, you can create a pull request to merge your changes from there as well.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Merging a Pull Request&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Inside of your Pull request, click Merge pull request&lt;/li&gt;
&lt;li&gt;Click Confirm merge&lt;/li&gt;
&lt;li&gt;Once your branch has been merged, you don’t need it anymore. You can click Delete branch!&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Summing up
&lt;/h2&gt;

&lt;p&gt;And that’s it! You’ve learned how to work collaboratively on projects using GitHub. GitHub is an amazing tool to take advantage of! You can now create repositories and issues, create branches, fork projects and make commits, submit pull requests for review, and merge to the master branch. Not bad!&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>An Introduction to PUG</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Thu, 29 Sep 2022 02:10:48 +0000</pubDate>
      <link>https://dev.to/timothyrobards/an-introduction-to-pug-2f11</link>
      <guid>https://dev.to/timothyrobards/an-introduction-to-pug-2f11</guid>
      <description>&lt;p&gt;&lt;strong&gt;Pug&lt;/strong&gt; (formerly known as Jade) is a preprocessor which simplifies the task of writing HTML. It also adds a ton of functionality, such as objects, conditionals, loops, mixins and templates. The syntax is arguably a lot cleaner to read and it can be a real time-saver when working with a lot of HTML (especially frameworks such as Bootstrap, Foundation, etc).&lt;/p&gt;

&lt;p&gt;Lets take a peek at some Pug syntax &amp;amp; compare it to regular HTML..&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// index.pug
doctype html  
html(lang='en')  
 head
   title Pug demo
 body
   h1 Welcome to Pug Life
   div.container
     p I'm a p that needs to be contained!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Note the use of indentation to nest our HTML as we require. And the lack of closing tags!&lt;/p&gt;

&lt;p&gt;And here’s the standard HTML output:&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="c"&gt;&amp;lt;!-- index.html --&amp;gt;&lt;/span&gt;

&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;  
&lt;span class="nt"&gt;&amp;lt;html&lt;/span&gt; &lt;span class="na"&gt;lang=&lt;/span&gt;&lt;span class="s"&gt;"en"&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;title&amp;gt;&lt;/span&gt;Pug demo&lt;span class="nt"&gt;&amp;lt;/title&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;h1&amp;gt;&lt;/span&gt;Welcome to Pug Life&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
   &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"container"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
     &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;I'm a p that needs to be contained!&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
   &lt;span class="nt"&gt;&amp;lt;/div&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;By comparison our pug code is much more concise. Additionally, the compiler will throw errors if we have any mistakes in our code – which makes for convenient error prevention.&lt;/p&gt;

&lt;p&gt;So let’s get started!&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Install Pug
&lt;/h2&gt;

&lt;p&gt;Note: You’ll need NodeJS installed! Go ahead and &lt;a href="https://nodejs.org/en/download/"&gt;install&lt;/a&gt; if you haven’t already.&lt;/p&gt;

&lt;p&gt;To install pug run the following command from your terminal:&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 pug-cli
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We install globally with &lt;code&gt;-g&lt;/code&gt; as we’ll need access to Pug commands from terminal.&lt;/p&gt;

&lt;p&gt;Now in our root directory, create a file called &lt;code&gt;index.pug&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Let's test this out! Add the following text to our file as follows:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// file: index.pug

doctype html
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And lets compile it to HTML with the following command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;pug index.pug
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We should now see our &lt;code&gt;index.html&lt;/code&gt; generated in the root directory. It will of course convert to HTML as follows:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// file: index.html

&amp;lt;!DOCTYPE html&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When working on a larger project, you might want to use a more specific compile command, such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;pug -w ./ -o ./html -P
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;-w&lt;/code&gt; flag will watch our pug file for changes and re-compile automatically each time we save. &lt;code&gt;./&lt;/code&gt; will watch everything in the current directory. -&lt;code&gt;o ./html&lt;/code&gt; will set the output folder to html. &lt;code&gt;-P&lt;/code&gt; will make our HTML source code pretty printed, with indentation, line-breaks, etc.&lt;/p&gt;

&lt;p&gt;Note: Once you’ve executed this command, keep your terminal running to continue the auto-compile!&lt;/p&gt;

&lt;h2&gt;
  
  
  The Basics
&lt;/h2&gt;

&lt;p&gt;Let's get started on a basic HTML structure. Type up the following in your &lt;code&gt;index.pug&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;doctype html
html
  head
  body
    h1#title Lets get pugging!
    p I'm a paragraph
    p.
      I'm a multi-line paragraph!
      And this is the second line.
    p.para. 
      This paragraph has class!
    .firstDiv A div with a class.
    #secondDiv A div with an id.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Note the use of indentation! Make sure you tab your child elements.&lt;/p&gt;

&lt;p&gt;When you save and open up &lt;code&gt;index.html.&lt;/code&gt; You’ll see the complete HTML generated like so..&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;&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;h1&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"title"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;Lets get pugging!&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;I'm a paragraph&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;
      I'm a multi-line paragraph!
      And this is the second line.
    &lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"para"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;This paragraph has class!&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"firstDiv"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;A div with a class.&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;       
    &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"secondDiv"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;A div with an id.&lt;span class="nt"&gt;&amp;lt;/div&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;h2&gt;
  
  
  Attributes
&lt;/h2&gt;

&lt;p&gt;Let's take a look some syntax for setting attributes in pug.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;doctype html
html
  head
    //- Invisible comment.
    //Visible comment.    
    script(src="script.js")
    link(rel='stylesheet', href='css/main.css')
  body
    a(href="https://google.com") google.com
    img(src="https://google.com/logo.png" alt="google logo")
    input(type="password" name ="inputpass")
    input(type='checkbox' checked)
    input(type='checkbox' checked=true)
    input(type='checkbox' checked=false)
    //Inline styles
    a(href="your-link", style={color: "Red", "font-size": "24px"}) I'm a link!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our HTML will generate as follows:&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="c"&gt;&amp;lt;!--Visible comment.--&amp;gt;&lt;/span&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;"script.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;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;"css/main.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;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"https://google.com"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;google.com&lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"https://google.com/logo.png"&lt;/span&gt; &lt;span class="na"&gt;alt=&lt;/span&gt;&lt;span class="s"&gt;"google logo"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;

    &lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"password"&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"inputpass"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"checkbox"&lt;/span&gt; &lt;span class="na"&gt;checked&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"checkbox"&lt;/span&gt; &lt;span class="na"&gt;checked&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"checkbox"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="c"&gt;&amp;lt;!--Inline styles--&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"your-link"&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"color:Red;font-size:24px;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;I'm a  link!&lt;span class="nt"&gt;&amp;lt;/a&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;h2&gt;
  
  
  Adding JavaScript
&lt;/h2&gt;

&lt;p&gt;One of the most powerful features of Pug, is the ability to easily make our HTML dynamic, using inline JavaScript. Lets take a look at a few examples:&lt;/p&gt;

&lt;h3&gt;
  
  
  Variables
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;- let name = 'Timothy'
- let city = 'Montreal'
- let transport = { type: 'Bike' }
- let food = ['Tacos', 'Pizza', 'Cheetos']

// Incrementation for numeric variables
age++

// Assigning variables to elements
p= name
span.age= age
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Interpolation
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;- let size ="medium"
  img(src=`https://google.com/logo-${size}.png` alt="logo")
---------------------

// output:
&amp;lt;img src="https://google.com/logo-medium.png" alt="logo"&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Loops
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ul
  each city in ['Sydney', 'Montreal', 'New York']
    li= city
ul
  each city, index in ['Sydney', 'Montreal', 'New York']
    li= 'Number ' + index + ': ' + city
-------------------------------------------------
// output:
&amp;lt;ul&amp;gt;
  &amp;lt;li&amp;gt;Sydney&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;Montreal&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;New York&amp;lt;/li&amp;gt;
&amp;lt;/ul&amp;gt;
&amp;lt;ul&amp;gt;
  &amp;lt;li&amp;gt;Number 0: Sydney&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;Number 1: Montreal&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;Number 2: New York&amp;lt;/li&amp;gt;
&amp;lt;/ul&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Conditionals
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;if user
  h2 Welcome back #{user}!
else if admin
  h2 Hey #{admin}!
else
  h2 Sign up!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Mixins
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Declaration
mixin list
  ul
    li Sydney
    li Montreal
    li New York
// Use
+list
+list
------------------
// output:
&amp;lt;ul&amp;gt;
  &amp;lt;li&amp;gt;Sydney&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;Montreal&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;New York&amp;lt;/li&amp;gt;
&amp;lt;/ul&amp;gt;
&amp;lt;ul&amp;gt;
  &amp;lt;li&amp;gt;Sydney&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;Montreal&amp;lt;/li&amp;gt;
  &amp;lt;li&amp;gt;New York&amp;lt;/li&amp;gt;
&amp;lt;/ul&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Mixins compile as functions, and therefore can take arguments!&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;mixin city(name)
  li.city= name
ul
  +city('Sydney')
  +city('Montreal')
  +city('New York')
--------------------
// output:
&amp;lt;ul&amp;gt;
  &amp;lt;li class="city"&amp;gt;Sydney&amp;lt;/li&amp;gt; 
  &amp;lt;li class="city"&amp;gt;Montreal&amp;lt;/li&amp;gt;
  &amp;lt;li class="city"&amp;gt;New York&amp;lt;/li&amp;gt;
&amp;lt;/ul&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The features we’ve looked at here are really just the tip of the iceberg! For the full specs check out &lt;a href="https://pugjs.org/api/getting-started.html"&gt;PugJS.org — Getting Started&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Structuring your Pug files
&lt;/h2&gt;

&lt;p&gt;A well organized template system is a crucial part of any development process. What follows is a look at how we can organize our projects using both &lt;code&gt;includes&lt;/code&gt; and &lt;code&gt;extends&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Includes
&lt;/h3&gt;

&lt;p&gt;Includes allow you to insert the contents of one Pug file into another. All you need to do is add an &lt;code&gt;include&lt;/code&gt; directive into your main pug file, as follows:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;doctype html
html
  include additions.pug
  body
    h1 My Heading
    p Here goes the text.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Lets now create the &lt;code&gt;additions.pug&lt;/code&gt; file and add the following content:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;head
  title My Site
  script(src='/js/jquery.js')
  script(src='/js/app.js')
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Our files will compile merged into &lt;code&gt;index.html&lt;/code&gt; like so:&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;title&amp;gt;&lt;/span&gt;My Site&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&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;"/js/jquery.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 &lt;/span&gt;&lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"/js/app.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;/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;h1&amp;gt;&lt;/span&gt;My Heading&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Here goes the text.&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;h3&gt;
  
  
  Extends
&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;extends&lt;/code&gt; keyword allows a template to extend a layout or parent template. It can then override certain pre-defined blocks of content, using the &lt;code&gt;block&lt;/code&gt; command.&lt;/p&gt;

&lt;p&gt;We want to keep our projects as organized as possible! A logical template system will define a base template, and then all the other templates extend from it. For example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// file: index.pug

extends layout.pug

block content
  h1 hello world!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here we’ve set our &lt;code&gt;index.pug&lt;/code&gt; file as the base template. With a call to the &lt;code&gt;layout.pug&lt;/code&gt; file via extends.&lt;/p&gt;

&lt;p&gt;Note the use of the &lt;code&gt;block&lt;/code&gt; command. This is how we direct part of a template to be extended.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// file: layout.pug

doctype html
html(lang="en")
  head
    meta(charset='utf-8')
  body
    block content
    h2 hello again world!

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here is the content of our layout.pug, we use the &lt;code&gt;block&lt;/code&gt; command with the same name (you can call it whatever you like!), so the pug engine knows where to put the code block.&lt;/p&gt;

&lt;p&gt;This code will compile as follows:&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&lt;/span&gt; &lt;span class="na"&gt;lang=&lt;/span&gt;&lt;span class="s"&gt;"en"&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;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;/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;h1&amp;gt;&lt;/span&gt;hello world!&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;hello again world!&lt;span class="nt"&gt;&amp;lt;/h2&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;Of course you can use as many blocks as you like, and create as many pug files as you like. The point is to build a logical structure into our projects &amp;amp; keep our code clean and organized!&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;And that’s it! We’ve setup a Pug development environment and covered the fundamentals. We’ve looked at many of the features provided by adding JavaScript such as variables, interpolation, loops, conditionals and mixins. We’ve also looked at how to structure our Pug files using templating with the include and extend directives.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>50 Best Eleventy Starter Themes</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Wed, 03 Feb 2021 16:46:53 +0000</pubDate>
      <link>https://dev.to/timothyrobards/50-best-eleventy-starter-themes-f5j</link>
      <guid>https://dev.to/timothyrobards/50-best-eleventy-starter-themes-f5j</guid>
      <description>&lt;p&gt;Eleventy (or 11ty) is a Static Site Generator that aims to be a simpler alternative to Jekyl. It has been steadily gaining popularity in recent times, with 8.4K GitHub stars and 238 GitHub forks and growing!&lt;/p&gt;

&lt;p&gt;It's completely open-source, written in JavaScript and unlike other SSG's (Gatsby, NuxtJS) it doesn't come bundled with a front-end library. Instead, it takes a series of templates, markdown files, and data and renders them as HTML. Eleventy works with HTML, Markdown, Liquid, Nunjucks, Handlebars, Mustache, EJS, Haml, Pug, and JavaScript Template Literals. Find out more at the &lt;a href="https://www.11ty.dev/"&gt;official site&lt;/a&gt;!&lt;/p&gt;

&lt;p&gt;So without further ado, here are 50 Eleventy starter themes to kick off 2021!&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Eleventyone
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ffti96rhp0hww5dh30bhk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ffti96rhp0hww5dh30bhk.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A scaffold for a quick start building with the Eleventy SSG.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/philhawksworth/eleventyone"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Smix Eleventy Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fnp0bz9ytdbyjhsn98zt1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fnp0bz9ytdbyjhsn98zt1.png" alt="Alt Text" width="800" height="631"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A starter kit for Eleventy v0.11.1 and Forestry CMS/Netlify. Based on gulp v4.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/hirusi/smix-eleventy-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3. tai11s
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foglgxp33np85u9odo00z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foglgxp33np85u9odo00z.png" alt="Alt Text" width="800" height="550"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;An Eleventy starter with Tailwind CSS and PurgeCSS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/danfascia/tai11s"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. 11ty.js
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F1f2b92wo7lt6ee69ccyo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F1f2b92wo7lt6ee69ccyo.png" alt="Alt Text" width="800" height="546"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;An Eleventy starter project using JavaScript templates.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://gitlab.com/reubenlillie/eleventy-dot-js-blog"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  5. pugsum
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fv2fiukr9eru7i9dp5m9b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fv2fiukr9eru7i9dp5m9b.png" alt="Alt Text" width="800" height="488"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;An 11ty starter kit using Pug Templates and TailwindCSS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/vktrwlt/pugsum"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Industrial Empathy
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Flgglolvr4nf9hcxgbm7d.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Flgglolvr4nf9hcxgbm7d.png" alt="Alt Text" width="800" height="607"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A high-performance blog template for the 11ty static site generator.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/google/eleventy-high-performance-blog"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  7. 11ty Contentful Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzu3lk57pdieo63jinspm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzu3lk57pdieo63jinspm.png" alt="Alt Text" width="800" height="604"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A Contentful 11ty starter project.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/contentful/11ty-contentful-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  8. Vredeburg
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fef25cevbrv78w0f3fnl7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fef25cevbrv78w0f3fnl7.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A simple starter project to create a blog using Eleventy and Tailwind CSS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/dafiulh/vredeburg"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  9. Eleventy Duo
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fse9kjq7w2pd7510h2fxw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fse9kjq7w2pd7510h2fxw.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Eleventy Duo is a minimal and beautiful Eleventy theme for personal blogs.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/yinkakun/eleventy-duo"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  10. Neat Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fkrjwa9s3izz5w69e56c4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fkrjwa9s3izz5w69e56c4.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Starter template for Netlify CMS, Eleventy, Alpine JS &amp;amp; Tailwind CSS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/surjithctly/neat-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  11. 11r
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0y20dqsplvxbotv5hzf7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0y20dqsplvxbotv5hzf7.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A blog template and theme using 11ty, TailwindCSS, Rollup, Prism syntax highlighting, etc.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/reeseschultz/11r"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  12. YAES
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foyya1kvr5hu61yhtoqbs.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foyya1kvr5hu61yhtoqbs.png" alt="Alt Text" width="800" height="647"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Starter kit for your next eleventy(11ty) project using postcss, es6, snowpack, webpack.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/22mahmoud/YAES"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  13. Fundamenty
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fevo8j1gzm4kxqx7k5wyg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fevo8j1gzm4kxqx7k5wyg.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;11ty Starter with Multi-language support, SEO-friendly, GitHub/GitLab Pages-ready.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/creasoft-dev/fundamenty"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  14. Eleventy Starter Boilerplate
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foiovbosluh4b2qpckcip.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Foiovbosluh4b2qpckcip.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Eleventy Starter Boilerplate is production-ready with SEO-friendly for quickly starting a blog.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/ixartz/Eleventy-Starter-Boilerplate"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  15. Minimal 11ty Tailwind Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F9z8mz7iyr4jfkwuz16hw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F9z8mz7iyr4jfkwuz16hw.png" alt="Alt Text" width="800" height="326"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A very minimal eleventy starter using Tailwind CSS for styling. It features a smart navigation component that sets active states automatically.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/tomreinert/minimal-11ty-tailwind-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  16. Dark Portfolio Theme for 11ty
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fc1uijs8dyjswhf27slxx.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fc1uijs8dyjswhf27slxx.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is a port of the Dark Portfolio Template by W3C to 11ty!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/jmschrack/Dark-Portfolio-Template-11ty/"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  17. 11tyFrame
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fxm2u6f5mq38f72t0vsdm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fxm2u6f5mq38f72t0vsdm.png" alt="Alt Text" width="800" height="461"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A light site frame using Eleventy static site generator.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/octoxalis/11tyframe"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  18. Eleventy Hylia
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzwrjxzc7tayyxep0c8y8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fzwrjxzc7tayyxep0c8y8.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Hylia is a lightweight Eleventy starter kit to help you to create your own blog or personal website.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/andybelldesign/hylia"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  19. Eleventy Hylia Forestry
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fki8bcmtztnf6fqal9obs.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fki8bcmtztnf6fqal9obs.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Hylia is a lightweight Eleventy starter kit with Forestry CMS pre-configured, so that you can one-click install a progressive, accessible blog in minutes. It also gives you a well-organized starting point to extend it for yourself.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/DirtyF/hylia-forestry"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  20. Seven
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F86sydk67pdj8tjtulrm2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F86sydk67pdj8tjtulrm2.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;An Eleventy template using Bootstrap, Sass, Webpack, Vue.js powered search, includes lots of other features.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/planetoftheweb/seven"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  21. Eleventy Starter Ghost
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fg124ad21abzlg33b6neb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fg124ad21abzlg33b6neb.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A starter template to build websites with Ghost &amp;amp; Eleventy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/TryGhost/eleventy-starter-ghost"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  22. Eleventy Minimal Blog
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fberwvz34ajny535rp36j.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fberwvz34ajny535rp36j.png" alt="Alt Text" width="800" height="236"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A minimal blog template using eleventy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/arpitbatra123/eleventy-blog-mnml"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  23. Skeleventy
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fgh6mmqws392hjfzrsrcu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fgh6mmqws392hjfzrsrcu.png" alt="Alt Text" width="800" height="518"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A skeleton boilerplate built with Eleventy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/josephdyer/skeleventy"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  24. Eleventy 2 Snipcart
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F01v9bdi9qupnbl2c5m3m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F01v9bdi9qupnbl2c5m3m.png" alt="Alt Text" width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A demo snipcart app built with 11ty.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/snipcart/11ty-demo-snipcart"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  25. Medium Export
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fxbn9ij9ogh31rqfun4ft.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fxbn9ij9ogh31rqfun4ft.png" alt="Alt Text" width="800" height="542"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A demo of generating a JAMstack site from an RSS feed.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/philhawksworth/medium-export"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  26. Eleventy NetlifyCMS Boilerplate
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fgukjgwp91yb4w929w9v4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fgukjgwp91yb4w929w9v4.png" alt="Alt Text" width="800" height="431"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A boilerplate for building a simple website with the Eleventy static site generator.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/danurbanowicz/eleventy-netlify-boilerplate"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  27. Eleventy Base Blog
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fqwzib33xgom726t2k5h9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fqwzib33xgom726t2k5h9.png" alt="Alt Text" width="800" height="423"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A starter repository for a blog web site using the Eleventy static site generator.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/11ty/eleventy-base-blog"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  28. Hawksworth
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Funsf98wgkymn7xposnd9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Funsf98wgkymn7xposnd9.png" alt="Alt Text" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A blog site, powered by Eleventy and Netlify.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/philhawksworth/hawksworx.com"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  29. Eleventy About Me
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fdvfrbdgph79w37kbohig.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fdvfrbdgph79w37kbohig.png" alt="Alt Text" width="800" height="453"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A personal website template, built with Eleventy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/panos/eleventy-about-me"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  30. Twelvety
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fofknhtufa1fy3zpuy98x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fofknhtufa1fy3zpuy98x.png" alt="Alt Text" width="800" height="710"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Twelvety is a pre-configured Eleventy starter project built to be fast.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/gregives/twelvety"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  31. 11ty Contentful Gallery
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fvxkvc94fbiz2r76ejjrn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fvxkvc94fbiz2r76ejjrn.png" alt="Alt Text" width="800" height="550"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;An example photo gallery made using Contentful and 11ty.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/contentful/11ty-contentful-gallery"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  32. Eleventy React Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fg0kz3kws5f9bpovpcldo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fg0kz3kws5f9bpovpcldo.png" alt="Alt Text" width="800" height="423"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Use React components in Eleventy!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/signalkuppe/eleventy-react"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  33. JAMStack Web Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fj1fnbemnvrh4c2eslpgm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fj1fnbemnvrh4c2eslpgm.png" alt="Alt Text" width="800" height="410"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Static website workflow utilizing Eleventy, Tailwind CSS, Webpack and PostCSS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/scottishstoater/jamstack-web-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  34. Agility CMS Eleventy Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fh9pk8bvqau5e53yzopf6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fh9pk8bvqau5e53yzopf6.png" alt="Alt Text" width="800" height="601"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A sample Eleventy starter that uses Agility CMS and aims to be a foundation for building fully static sites using 11ty and Agility CMS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/agility/agilitycms-eleventy-starter-2020"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  35. 11st Starter Kit
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F82bir6f6w9whi4lfxpxh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F82bir6f6w9whi4lfxpxh.png" alt="Alt Text" width="800" height="451"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;11ty, powered by Snowpack with Tailwind CSS and Alpine.js.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/stefanfrede/11st-starter-kit"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  36. XITY Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fc3uzll10vwf781uvoch9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fc3uzll10vwf781uvoch9.png" alt="Alt Text" width="800" height="603"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A blog-ready 11ty starter based on PostCSS, with RSS feed and Native Elements.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/equinusocio/xity-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  37. pack11ty
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ft6hbnly44ebr3c7d4e1v.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ft6hbnly44ebr3c7d4e1v.png" alt="Alt Text" width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A heavily opinionated Eleventy template project!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/nhoizey/pack11ty"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  38. Eleventy Classic Blog Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fstwg0jtkc4ykh0xxr64k.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fstwg0jtkc4ykh0xxr64k.png" alt="Alt Text" width="800" height="435"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A starter repository for a classic blog website using the Eleventy SSG.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/TigersWay/eleventy-classic-blog-starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  39. 11ta Template
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fy2rp3ydh4en9thvz3e3r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fy2rp3ydh4en9thvz3e3r.png" alt="Alt Text" width="800" height="679"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Deeply customizable, full-featured, ready to publish blog template built with 11ty, TailwindCSS, &amp;amp; Alpine.js.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/11ta/11ta-template"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  40. JET
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fjb3zabndypk17f7gd90p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fjb3zabndypk17f7gd90p.png" alt="Alt Text" width="800" height="321"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It‘s (j)ust (e)leventy and (t)ailwind … OK, and a few other things; it‘s still really small though.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/marcamos/jet"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  41. rocket11ty
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fl89atmug08iwj9btfz7r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fl89atmug08iwj9btfz7r.png" alt="Alt Text" width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A simple halfmoon 11ty blog based on eleventy-base-blog.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/aboutDavid/rocket11ty"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  42. 11ty Netlify Jumpstart
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F7qoflrn8ikvuy3xc23lg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F7qoflrn8ikvuy3xc23lg.png" alt="Alt Text" width="800" height="465"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Quickly launch an 11ty-generated static site. Includes a minimal Sass framework, and generated sitemap, RSS feed, and social share preview images.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://11ty-netlify-jumpstart.netlify.app/"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  43. Supermaya
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fsfdjelcotxwb2q0uh1ok.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fsfdjelcotxwb2q0uh1ok.png" alt="Alt Text" width="800" height="596"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Supermaya is an Eleventy starter kit designed to help you add rich features to a blog or website without the need for a complicated build process.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/madebymike/supermaya"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  44. Eleventy Webpack
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ff68vzg1sc6xd270r3e6a.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Ff68vzg1sc6xd270r3e6a.png" alt="Alt Text" width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A barebones Eleventy and Webpack boilerplate.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/clenemt/eleventy-webpack"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  45. 11tyby
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fye8h9ri00qeckqynhvsj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fye8h9ri00qeckqynhvsj.png" alt="Alt Text" width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Simple 11ty setup using TypeScript, SASS, Preact with partial hydration, and other useful things. Aims to provide the DX of Gatsby, but using 11ty!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/jhukdev/11tyby"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  46. Eleventy Encore
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fqfcerpelmy71389ka41u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fqfcerpelmy71389ka41u.png" alt="Alt Text" width="800" height="661"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Basic 11ty setup using webpack encore.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/disjfa/eleventy-encore"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  47. Twenty Ninety
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fn145r016y1ewpdg70xck.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fn145r016y1ewpdg70xck.png" alt="Alt Text" width="800" height="611"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A production-ready Eleventy starter kit, optimized for performance.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/seancdavis/twenty-ninety"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  48. Eleventy Solo Starter
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fog6rs792oba0hdh663kd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fog6rs792oba0hdh663kd.png" alt="Alt Text" width="800" height="528"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A starter set for the Eleventy static site generator (SSG).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/brycewray/eleventy_solo_starter"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  49. Eleventy Site
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fah5q5scoefmpkxpl4d36.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fah5q5scoefmpkxpl4d36.png" alt="Alt Text" width="800" height="391"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A simple eleventy starter site.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/bjankord/eleventy-site"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  50. Elevenpack
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F1sts5h1yqqblnw4f5wd3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F1sts5h1yqqblnw4f5wd3.png" alt="Alt Text" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Eleventy starter pack with modern JS and CSS workflows.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/deviousdodo/elevenpack"&gt;See more details&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Enjoy 😊&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>codenewbie</category>
      <category>javascript</category>
      <category>programming</category>
    </item>
    <item>
      <title>Structuring your SASS projects</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Tue, 10 Nov 2020 00:52:00 +0000</pubDate>
      <link>https://dev.to/timothyrobards/structuring-your-sass-projects-50cm</link>
      <guid>https://dev.to/timothyrobards/structuring-your-sass-projects-50cm</guid>
      <description>&lt;p&gt;Let’s take a look at how we can structure our Sass projects!&lt;/p&gt;

&lt;p&gt;As projects grow and expand, the need to modularize our directory and file structure increases dramatically. Thus keeping our files and folders organized is crucial. We also have the added benefit of creating components that can be reused across multiple projects. There is no one “correct” structure — its entirely up to you!&lt;/p&gt;

&lt;h2&gt;
  
  
  How do we structure our Sass projects?
&lt;/h2&gt;

&lt;p&gt;We do this by dividing up our stylesheets into separate files using &lt;em&gt;Partials&lt;/em&gt;. The separate files will represent different components. We then &lt;em&gt;import&lt;/em&gt; our partials using an &lt;code&gt;@import&lt;/code&gt; directive, into one master stylesheet — typically the &lt;code&gt;main.scss&lt;/code&gt; file. For example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="c1"&gt;// File: main.scss&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/header';&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We could then create a layout folder for our layout specific files, such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="c1"&gt;// File: _header.scss&lt;/span&gt;

&lt;span class="c1"&gt;// This file contains all styles related to the header of the site/application.&lt;/span&gt;

&lt;span class="cm"&gt;/* STYLES GO HERE */
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Remember:&lt;/em&gt; The name of a partial file should always begin with an underscore &lt;code&gt;_&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Next up, let’s take a look at some of the ways we could choose to structure our projects!&lt;/p&gt;

&lt;p&gt;Keep in mind that there is no one &lt;em&gt;correct&lt;/em&gt; structure — it’s entirely up to you!&lt;/p&gt;

&lt;p&gt;Lets take a look at how to go about structuring your projects..&lt;/p&gt;

&lt;h2&gt;
  
  
  Simple Structure
&lt;/h2&gt;

&lt;p&gt;If you’re using Sass on a small project, for example - a single web page. A very minimal structure could be as follows:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="nt"&gt;_base&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;
&lt;span class="nt"&gt;_layout&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;
&lt;span class="nt"&gt;_components&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;

&lt;span class="nt"&gt;main&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here we have 3 partials connecting up to our &lt;code&gt;main.scss&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Base:&lt;/strong&gt; contained within this file are all y*o*ur resets, variables, mixins, and any utility classes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Layout:&lt;/strong&gt; contains all the CSS that handles the layout, such as the container and any grid systems.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Components:&lt;/strong&gt; anything reusable such as buttons, navbars, cards etc.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Main:&lt;/strong&gt; it should ONLY contain the imports for the above files.&lt;/p&gt;

&lt;p&gt;If any file grows too cluttered or disorganized, it’s time to expand our structure. Consider adding a folder for your components for example, and breaking it up into individual files such as &lt;code&gt;_button.scss&lt;/code&gt; &amp;amp; &lt;code&gt;_carousel.scss&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;However, when we’re working on a larger project, we’ll need a more rigorous architecture, which we’ll look at in the next section.&lt;/p&gt;

&lt;h2&gt;
  
  
  The 7–1 Pattern
&lt;/h2&gt;

&lt;p&gt;The architecture known as the &lt;em&gt;7–1 pattern&lt;/em&gt; (7 folders, 1 file), is a widely-adopted structure that serves as a basis for large projects. You have all your partials organized into 7 different folders, and a single file sits at the root level (usually named &lt;code&gt;main.scss&lt;/code&gt;) to handle the imports — which is the file you compile into CSS.&lt;/p&gt;

&lt;p&gt;Here’s a sample 7–1 directory structure, I’ve included some examples of files that would sit inside of each folder:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="nt"&gt;sass&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;abstracts&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="nt"&gt;or&lt;/span&gt; &lt;span class="nt"&gt;utilities&lt;/span&gt;&lt;span class="o"&gt;/)&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_variables&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;    &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Sass&lt;/span&gt; &lt;span class="nt"&gt;Variables&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_functions&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;    &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Sass&lt;/span&gt; &lt;span class="nt"&gt;Functions&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_mixins&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;       &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Sass&lt;/span&gt; &lt;span class="nt"&gt;Mixins&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;base&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_reset&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;        &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Reset&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nt"&gt;normalize&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_typography&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;   &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Typography&lt;/span&gt; &lt;span class="nt"&gt;rules&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;components&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="nt"&gt;or&lt;/span&gt; &lt;span class="nt"&gt;modules&lt;/span&gt;&lt;span class="o"&gt;/)&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_buttons&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;      &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Buttons&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_carousel&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;     &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Carousel&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_slider&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;       &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Slider&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;layout&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_navigation&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;   &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Navigation&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_grid&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;         &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Grid&lt;/span&gt; &lt;span class="nt"&gt;system&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_header&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;       &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Header&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_footer&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;       &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Footer&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_sidebar&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;      &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Sidebar&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_forms&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;        &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Forms&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;pages&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_home&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;         &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Home&lt;/span&gt; &lt;span class="nt"&gt;specific&lt;/span&gt; &lt;span class="nt"&gt;styles&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_about&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;        &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;About&lt;/span&gt; &lt;span class="nt"&gt;specific&lt;/span&gt; &lt;span class="nt"&gt;styles&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_contact&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;      &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Contact&lt;/span&gt; &lt;span class="nt"&gt;specific&lt;/span&gt; &lt;span class="nt"&gt;styles&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;themes&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_theme&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;        &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Default&lt;/span&gt; &lt;span class="nt"&gt;theme&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_admin&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;        &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Admin&lt;/span&gt; &lt;span class="nt"&gt;theme&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;vendors&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_bootstrap&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;    &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Bootstrap&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="err"&gt;–&lt;/span&gt; &lt;span class="nt"&gt;_jquery-ui&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;    &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;jQuery&lt;/span&gt; &lt;span class="nt"&gt;UI&lt;/span&gt;
&lt;span class="o"&gt;|&lt;/span&gt;
&lt;span class="err"&gt;`–&lt;/span&gt; &lt;span class="nt"&gt;main&lt;/span&gt;&lt;span class="nc"&gt;.scss&lt;/span&gt;              &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="nt"&gt;Main&lt;/span&gt; &lt;span class="nt"&gt;Sass&lt;/span&gt; &lt;span class="nt"&gt;file&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Abstracts (or utilities):&lt;/strong&gt; holds Sass tools, helper files, variables, functions, mixins and other config files. These files are meant to be just helpers which don’t output any CSS when compiled.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Base:&lt;/strong&gt; holds the boilerplate code for the project. Including standard styles such as resets and typographic rules, which are commonly used throughout your project.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Components (or modules):&lt;/strong&gt; holds all of your styles for buttons, carousels, sliders, and similar page components (think widgets). Your project will typically contain a lot of component files — as the whole site/app should be mostly composed of small modules.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Layout:&lt;/strong&gt; contains all styles involved with the layout of your project. Such as styles for your header, footer, navigation and the grid system.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pages:&lt;/strong&gt; any styles specific to individual pages will sit here. For example it’s not uncommon for the home page of your site to require page specific styles that no other page receives.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Themes:&lt;/strong&gt; this is likely not used in many projects. It would hold files that create project specific themes. For example if sections of your site contain alternate color schemes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Vendors:&lt;/strong&gt; contains all third party code from external libraries and frameworks — such as Normalize, Bootstrap, jQueryUI, etc. However, there is often a need to override vendor code. If this is required, its good practice to create a new folder called &lt;code&gt;vendors-extensions/&lt;/code&gt; and then name any files after the vendors they overwrite. The file&lt;code&gt;vendors-extensions/_bootstrap.scss&lt;/code&gt; would contain all your Bootstrap overrides — as editing the vendor files themselves, isn’t generally a good idea.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Main.scss:&lt;/strong&gt; This file should only contain your imports! For example..&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'abstracts/variables';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'abstracts/functions';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'abstracts/mixins';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'vendors/bootstrap';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'vendors/jquery-ui';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'base/reset';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'base/typography';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/navigation';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/grid';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/header';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/footer';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/sidebar';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'layout/forms';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'components/buttons';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'components/carousel';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'components/slider';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'pages/home';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'pages/about';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'pages/contact';&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'themes/theme';&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'themes/admin';&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Note&lt;/em&gt;: There’s no need to include the &lt;code&gt;_&lt;/code&gt; or &lt;code&gt;.scss&lt;/code&gt; file extension when importing.&lt;/p&gt;

&lt;h2&gt;
  
  
  Get up and running with 7–1:
&lt;/h2&gt;

&lt;p&gt;The official boilerplate is up on &lt;a href="https://github.com/HugoGiraudel/sass-boilerplate"&gt;github&lt;/a&gt;. You can download or clone it with the following terminal command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git clone https://github.com/HugoGiraudel/sass-boilerplate.git
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;And that’s it! You’ve learned how you can go about structuring your Sass projects. The thing to keep in mind is that there are no explicit rules here. You should structure your projects in a way that is meaningful to you (and your team!). The way that helps you quickly and easily find and isolate your styles — is the way to go!&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>sass</category>
      <category>codenewbie</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>The Main Features of SASS</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Thu, 22 Oct 2020 01:05:38 +0000</pubDate>
      <link>https://dev.to/timothyrobards/the-main-features-of-sass-47k2</link>
      <guid>https://dev.to/timothyrobards/the-main-features-of-sass-47k2</guid>
      <description>&lt;p&gt;SASS effectively gives us a lot of the programmatic benefits of working with code, only now with the ability to apply it to stylesheets. &lt;/p&gt;

&lt;p&gt;In this post, we'll be diving right into the features of SASS, including:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Variables &lt;/li&gt;
&lt;li&gt;Nesting&lt;/li&gt;
&lt;li&gt;Mixins&lt;/li&gt;
&lt;li&gt;Functions&lt;/li&gt;
&lt;li&gt;Partials &amp;amp; Importing&lt;/li&gt;
&lt;li&gt;Inheritance&lt;/li&gt;
&lt;li&gt;The '&amp;amp;' Operator&lt;/li&gt;
&lt;li&gt;Control Directives&lt;/li&gt;
&lt;li&gt;Interpolation&lt;/li&gt;
&lt;li&gt;Placeholders&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Let's get started!&lt;/p&gt;

&lt;h2&gt;
  
  
  SASS Variables
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Variables&lt;/strong&gt; are a way to store information that you want to reuse throughout your stylesheet. &lt;/p&gt;

&lt;p&gt;They allow us to store values for colors, fonts or really any CSS value that you want to reuse!&lt;/p&gt;

&lt;p&gt;We use the &lt;code&gt;$&lt;/code&gt; symbol when we wish to make something a variable. &lt;/p&gt;

&lt;p&gt;Let's see an example!&lt;/p&gt;

&lt;p&gt;In our SCSS, define a color variable like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nv"&gt;$color-primary&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mh"&gt;#ffff00&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt; &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="n"&gt;Yellow&lt;/span&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$color-primary&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;This will of course, set our &lt;code&gt;background-color&lt;/code&gt; to yellow. It's that simple! &lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; You can use single line comments in Sass with &lt;code&gt;//&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;When we then run our compile, it’ll output the following CSS:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mh"&gt;#ffff00&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;This becomes extremely powerful when working on large projects! &lt;/p&gt;

&lt;p&gt;If you wish to make a change to a colour used throughout your stylesheets, it’s much simpler to alter if the color is defined in one location, as a single variable.&lt;/p&gt;

&lt;p&gt;The alternative to changing the value of one variable defined at one location, is finding and replacing every reference to the value you want to change. This is a much more tedious task, especially if you want to implement a quick change, to test out a different color or font.&lt;/p&gt;

&lt;h2&gt;
  
  
  Nesting
&lt;/h2&gt;

&lt;p&gt;When you observe the structure of an HTML file, you’ll notice it has a very clear hierarchy:&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;title&amp;gt;&lt;/span&gt;Page Title&lt;span class="nt"&gt;&amp;lt;/title&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;h1&amp;gt;&lt;/span&gt;My First Heading&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;My first paragraph.&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;As you can see, HTML has a structure that makes it quite easy to read.&lt;/p&gt;

&lt;p&gt;CSS on the other hand, lacks this visual structure. Which is why it has a tendency to become disorganized quite quickly. &lt;/p&gt;

&lt;p&gt;Enter Sass nesting!&lt;/p&gt;

&lt;h3&gt;
  
  
  Definition
&lt;/h3&gt;

&lt;p&gt;Using nesting, we can nest child selectors inside of the parent selector.&lt;/p&gt;

&lt;p&gt;This results in much cleaner and less repetitive code.&lt;/p&gt;

&lt;h3&gt;
  
  
  Example
&lt;/h3&gt;

&lt;p&gt;Take the following HTML:&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;nav&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"navbar"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;ul&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Home&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Store&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Contact Us&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/nav&amp;gt;&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Using regular CSS, we would write this like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;orangered&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="nt"&gt;ul&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;list-style&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="nt"&gt;li&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&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;There’s a lot of repetition here. Each time we want to style a child of &lt;code&gt;navbar&lt;/code&gt;, we have to repeat the class name.&lt;/p&gt;

&lt;p&gt;With Sass nesting, we can write much cleaner code.&lt;/p&gt;

&lt;p&gt;Like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;orangered&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nt"&gt;ul&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;list-style&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;li&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Using indentation, you can now see the &lt;code&gt;ul&lt;/code&gt; and &lt;code&gt;li&lt;/code&gt; selectors are neatly nested inside the &lt;code&gt;navbar&lt;/code&gt; selector.&lt;/p&gt;

&lt;p&gt;We have a much less repetitive syntax, which is far easier to read! &lt;/p&gt;

&lt;h2&gt;
  
  
  SASS Mixins
&lt;/h2&gt;

&lt;p&gt;Mixins are an extremely powerful feature of Sass. We use them to group together multiple CSS declarations for reuse throughout our projects.&lt;/p&gt;

&lt;p&gt;Say we want to create a mixin to hold the vendor prefixes for a transform property.&lt;/p&gt;

&lt;p&gt;In SASS, we’d code it like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@mixin&lt;/span&gt; &lt;span class="nf"&gt;transform&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;-webkit-transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;180deg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="na"&gt;-ms-transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;180deg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;180deg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;To add the mixin into our code, we then use the &lt;code&gt;@include&lt;/code&gt; directive, like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;orangered&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nt"&gt;ul&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;list-style&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;li&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;transform&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;All the code in the transform mixin will now be applied to the &lt;code&gt;li&lt;/code&gt; element. You can also pass values into your mixins to make them even more flexible.&lt;/p&gt;

&lt;p&gt;Instead of adding a specified value, add a name (using a variable, like &lt;code&gt;property&lt;/code&gt;) to represent the value like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@mixin&lt;/span&gt; &lt;span class="nf"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;$property&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;-webkit-transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$property&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="na"&gt;-ms-transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$property&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$property&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Now we can pass in whatever value we like, whenever we call the mixin:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;transform&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;20deg&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h2&gt;
  
  
  SASS Functions
&lt;/h2&gt;

&lt;p&gt;Sass &lt;strong&gt;functions&lt;/strong&gt; can receive arguments and return a single value.&lt;/p&gt;

&lt;p&gt;They add an element of programming to writing CSS code, and we can now do math!&lt;/p&gt;

&lt;p&gt;The standard math operators &lt;code&gt;+&lt;/code&gt;, &lt;code&gt;-&lt;/code&gt;, &lt;code&gt;*&lt;/code&gt;, &lt;code&gt;/&lt;/code&gt;, and &lt;code&gt;%&lt;/code&gt; can all be utilized.&lt;/p&gt;
&lt;h3&gt;
  
  
  An example function
&lt;/h3&gt;

&lt;p&gt;The following function can accept two arguments, &lt;code&gt;$first-number&lt;/code&gt; and &lt;code&gt;$second-number&lt;/code&gt;. The value that is returned by the function is the sum of the two variables:&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@function&lt;/span&gt; &lt;span class="nf"&gt;add-numbers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;$first-number&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$second-number&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@return&lt;/span&gt; &lt;span class="nv"&gt;$first-number&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nv"&gt;$second-number&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Say we want to replace the value of a &lt;code&gt;padding&lt;/code&gt; property with the sum of two separate values.&lt;/p&gt;

&lt;p&gt;We would call our function and pass in the arguments like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.box1&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;add-numbers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;5px&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;The resulting CSS output would be:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.box1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&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;Lets see the full code:&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;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;title&amp;gt;&lt;/span&gt;Page Title&lt;span class="nt"&gt;&amp;lt;/title&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;nav&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"navbar"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;ul&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Home&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Store&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;Contact Us&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/nav&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;And our SASS:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@function&lt;/span&gt; &lt;span class="nf"&gt;add-numbers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;$first-number&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$second-number&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@return&lt;/span&gt; &lt;span class="nv"&gt;$first-number&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nv"&gt;$second-number&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.navbar&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;orangered&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;add-numbers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;5px&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="m"&gt;100px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nt"&gt;ul&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;list-style&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;li&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;As you can see, functions help you write more readable and DRY Sass, as you can utilize reusable logic in a very efficient manner. This can make a huge difference when you start working on larger and more complex projects!&lt;/p&gt;

&lt;h2&gt;
  
  
  SASS Partials &amp;amp; Importing
&lt;/h2&gt;

&lt;p&gt;Partials in SASS help us to break up our files into smaller files without affecting performance.&lt;/p&gt;

&lt;p&gt;The use of partials allows us to modularize our CSS, to help keep things maintainable.&lt;/p&gt;

&lt;p&gt;We divide up our Sass into separate files representing different components. A partials’ name will always start with an underscore &lt;code&gt;_&lt;/code&gt;. We then import the partial using an &lt;code&gt;@import&lt;/code&gt; directive.&lt;/p&gt;

&lt;h3&gt;
  
  
  Using Partials
&lt;/h3&gt;

&lt;p&gt;Let’s say our Sass file is getting rather large. We might choose to make a partial file that contains just the code that’s relevant to the header section; we’d call it &lt;code&gt;_header.scss&lt;/code&gt; and move the appropriate code into that new file.&lt;/p&gt;

&lt;p&gt;We would then import it back into &lt;code&gt;main.css&lt;/code&gt;, like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="c1"&gt;// In main.scss&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s"&gt;'header';&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; When you import a file, there’s no need to include the &lt;code&gt;_&lt;/code&gt; or &lt;code&gt;.scss&lt;/code&gt; file extension.&lt;/p&gt;

&lt;h3&gt;
  
  
  @import in CSS vs SASS
&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;@import&lt;/code&gt; directive is of course, also available in CSS. However, there is an important difference. Whenever an import statement is used in CSS, an HTTP request is made to the server. This increases the amount of resource requests and negatively affects the performance of a web page. SASS does not do that. SASS takes the file that you want to import from and combines it with the file you’re importing. So you can serve a single CSS file to the web browser, which does not affect the performance.&lt;/p&gt;

&lt;h2&gt;
  
  
  SASS Inheritance
&lt;/h2&gt;

&lt;p&gt;Another great feature of Sass is &lt;strong&gt;inheritance&lt;/strong&gt;. We implement this using the &lt;code&gt;@extend&lt;/code&gt; directive.&lt;/p&gt;

&lt;p&gt;Inheritance is a feature of SASS that allows multiple classes to share a common set of properties with one another.&lt;/p&gt;

&lt;h3&gt;
  
  
  An Example
&lt;/h3&gt;

&lt;p&gt;Some typical CSS code for styling a button:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.button&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#0000FF&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="err"&gt;//&lt;/span&gt; &lt;span class="err"&gt;Blue&lt;/span&gt;
  &lt;span class="nl"&gt;border&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt; &lt;span class="m"&gt;32px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-block&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1.5rem&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;If we happen to have a number of buttons on our website, all of which are styled in a similar manner, we would have a good case for inheritance!&lt;/p&gt;

&lt;p&gt;We would implement a secondary button via inheritance like so:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.button-secondary&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@extend&lt;/span&gt; &lt;span class="nc"&gt;.button&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mh"&gt;#4CAF50&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt; &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="n"&gt;Green&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;  


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Our &lt;code&gt;.button-secondary&lt;/code&gt; class will take on all of the properties and values set the &lt;code&gt;.button class&lt;/code&gt;, with the exception of &lt;code&gt;background-color&lt;/code&gt; which we’ve decided to set to green.&lt;/p&gt;

&lt;p&gt;The use of inheritance helps us to keep our code neat, clean and focused on constructing reusable components.&lt;/p&gt;

&lt;h2&gt;
  
  
  The '&amp;amp;' Operator in SASS
&lt;/h2&gt;

&lt;p&gt;The ampersand &lt;code&gt;&amp;amp;&lt;/code&gt; operator is often used when &lt;a href="https://www.easeout.co/blog/2020-07-16-nesting-in-sass" rel="noopener noreferrer"&gt;nesting&lt;/a&gt; in SASS and is an extremely useful feature.&lt;/p&gt;

&lt;p&gt;It can be a great time-saver, especially if you happen to be coding your stylesheets with the &lt;a href="http://getbem.com/introduction/" rel="noopener noreferrer"&gt;BEM methodology&lt;/a&gt;, or using any systematic naming convention for your class names.&lt;/p&gt;

&lt;p&gt;See the following HTML:&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;class = &lt;/span&gt;&lt;span class="s"&gt;"btn btn--red"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt; Click me! &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;Typical styling would be something like this:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.btn&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-block&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt; &lt;span class="m"&gt;32px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.btn--red&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#ff0000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="err"&gt;//&lt;/span&gt; &lt;span class="err"&gt;Red&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.btn&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#fff&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="err"&gt;//&lt;/span&gt; &lt;span class="err"&gt;White&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;With the &lt;code&gt;&amp;amp;&lt;/code&gt; operator we can be much more efficient:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.btn&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-block&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt; &lt;span class="m"&gt;32px&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;&amp;amp;&lt;/span&gt;&lt;span class="nt"&gt;--red&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mh"&gt;#ff0000&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt; &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="n"&gt;Red&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;&amp;amp;&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mh"&gt;#fff&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt; &lt;span class="o"&gt;//&lt;/span&gt; &lt;span class="n"&gt;White&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Notice that we’ve now nested the child selectors that use the same &lt;code&gt;.btn&lt;/code&gt; name, represented by the &lt;code&gt;&amp;amp;&lt;/code&gt; operator. name.&lt;/p&gt;

&lt;p&gt;When compiled the &lt;code&gt;&amp;amp;&lt;/code&gt; operator will be replaced by its enclosing selector name!&lt;/p&gt;

&lt;h2&gt;
  
  
  Understanding SASS Control Directives
&lt;/h2&gt;

&lt;p&gt;Control directives and expressions are used in SASS to include styles only under certain defined conditions.&lt;/p&gt;

&lt;p&gt;As a feature, they’re quite advanced and are mainly useful in mixins. Common directives include &lt;code&gt;@if&lt;/code&gt;, &lt;code&gt;@else&lt;/code&gt;, &lt;code&gt;@for&lt;/code&gt; and &lt;code&gt;@while&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  @if and &lt;a class="mentioned-user" href="https://dev.to/else"&gt;@else&lt;/a&gt;
&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;@if&lt;/code&gt; and &lt;code&gt;@else&lt;/code&gt; directives are similar to &lt;code&gt;if&lt;/code&gt; and &lt;code&gt;else&lt;/code&gt; statements in JavaScript.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;@if&lt;/code&gt; takes an expression and executes the styles contained within its block — if the evaluation &lt;strong&gt;is not false&lt;/strong&gt; (or null).&lt;/p&gt;

&lt;p&gt;&lt;code&gt;@else&lt;/code&gt; will then be checked, if the previous &lt;code&gt;@if&lt;/code&gt; evaluated to false.&lt;/p&gt;

&lt;p&gt;For example:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@mixin&lt;/span&gt; &lt;span class="nf"&gt;heading&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;$size&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@if&lt;/span&gt; &lt;span class="nv"&gt;$size&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="nb"&gt;large&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;@else&lt;/span&gt; &lt;span class="n"&gt;if&lt;/span&gt; &lt;span class="nv"&gt;$size&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="nb"&gt;medium&lt;/span&gt;&lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;3rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;@else&lt;/span&gt; &lt;span class="n"&gt;if&lt;/span&gt; &lt;span class="nv"&gt;$size&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="n"&gt;small&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;@else&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
  &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.h1&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;heading&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;large&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.h6&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;heading&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;small&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Here, we are using a &lt;em&gt;heading&lt;/em&gt; mixin which accepts &lt;code&gt;$size&lt;/code&gt; as an argument. We can have a different size for each of our headings depending on which value we pass to the mixin.&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;a class="mentioned-user" href="https://dev.to/for"&gt;@for&lt;/a&gt;
&lt;/h3&gt;

&lt;p&gt;You can use the &lt;code&gt;@for&lt;/code&gt; directive to execute a group of statements a specified number of times. Effectively this is a loop.&lt;/p&gt;

&lt;p&gt;It has two variations. The first uses the &lt;code&gt;through&lt;/code&gt; keyword, it’ll execute the statements from start to end, inclusive.&lt;/p&gt;

&lt;p&gt;An example using through:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@for&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt; &lt;span class="ow"&gt;from&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt; &lt;span class="ow"&gt;through&lt;/span&gt; &lt;span class="m"&gt;5&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
   &lt;span class="nc"&gt;.list-&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
   &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;This will produce the following CSS output:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.list-1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-2&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-3&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;6px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-4&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;8px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-5&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;10px&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;If we replace the &lt;code&gt;through&lt;/code&gt; keyword with &lt;code&gt;to&lt;/code&gt;, it makes the loop exclusive. The difference being that it won’t execute when the variable is equal to &lt;strong&gt;end&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;An example using &lt;code&gt;to&lt;/code&gt;:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@for&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt; &lt;span class="ow"&gt;from&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt; &lt;span class="ow"&gt;to&lt;/span&gt; &lt;span class="m"&gt;5&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
   &lt;span class="nc"&gt;.list-&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
   &lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;This produces the following CSS:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.list-1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-2&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-3&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;6px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.list-4&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;8px&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;h3&gt;
  
  
  &lt;a class="mentioned-user" href="https://dev.to/while"&gt;@while&lt;/a&gt;
&lt;/h3&gt;

&lt;p&gt;We could instead implement the above code using the &lt;code&gt;@while&lt;/code&gt; directive. As its name implies, it will continue to output CSS produced by the statements while the condition returns true.&lt;/p&gt;

&lt;p&gt;The syntax is as follows:&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@while&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="m"&gt;6&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;.list-&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;       
     &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;   
  &lt;span class="err"&gt;}&lt;/span&gt;
  &lt;span class="nv"&gt;$i&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$i&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;The output is identical, so you could opt for your personal preference based on the syntax.&lt;/p&gt;

&lt;h2&gt;
  
  
  SASS Interpolation
&lt;/h2&gt;

&lt;p&gt;Interpolation is essentially a code insertion. It allows us to interpolate SASS expressions into our code. We can use it to use a selector or property name, quoted or unquoted strings etc, as variables.&lt;/p&gt;

&lt;h3&gt;
  
  
  The syntax
&lt;/h3&gt;

&lt;p&gt;To interpolate an expression we need to wrap the expression using &lt;code&gt;#{ }&lt;/code&gt;.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$variable_name&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Let’s see an example that shows how we could use interpolation with a mixin:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="k"&gt;@mixin&lt;/span&gt; &lt;span class="nf"&gt;interpolation&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;$editable&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$val&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$val2&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$prop1&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;$prop2&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;background-&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$editable&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$val&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nv"&gt;$val2&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$prop1&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt; 
    &lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="nv"&gt;$prop2&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;span class="nc"&gt;.block1&lt;/span&gt;&lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;interpolation&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"image"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="sx"&gt;url("img.png")&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;top&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;right&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.block2&lt;/span&gt;&lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;@include&lt;/span&gt; &lt;span class="nd"&gt;interpolation&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"color"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="n"&gt;lightgray&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;top&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;left&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;This will compile in CSS as follows:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nc"&gt;.block1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-image&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sx"&gt;url("img.png")&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;right&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.block2&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
   &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;lightgray&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
   &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
   &lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
   &lt;span class="nl"&gt;left&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&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;As you can see, it’s quite easy to use this to create dynamically reusable code!&lt;/p&gt;

&lt;h3&gt;
  
  
  Main reasons to use Interpolation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;We can use dynamically created names as a property name, a variable name or for other similar purposes.&lt;/li&gt;
&lt;li&gt;We can create highly reusable code!&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  SASS Placeholders
&lt;/h2&gt;

&lt;p&gt;In SASS a &lt;strong&gt;placeholder&lt;/strong&gt; looks and acts a lot like a class selector, only it starts with a &lt;code&gt;%&lt;/code&gt; and it is not included in the CSS output.&lt;/p&gt;

&lt;p&gt;Our &lt;code&gt;%placeholder&lt;/code&gt; selector contains some width and height declarations:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;

&lt;span class="nv"&gt;%placeholder&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt;&lt;span class="err"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;@extend&lt;/span&gt; &lt;span class="nv"&gt;%placeholder&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;p&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;@extend&lt;/span&gt; &lt;span class="nv"&gt;%placeholder&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Note that we’ve used the &lt;code&gt;@extend&lt;/code&gt; directive, which allows one selector to inherit styles of another selector.&lt;/p&gt;

&lt;p&gt;This outputs to CSS as follows:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;

&lt;span class="nt"&gt;body&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nt"&gt;p&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&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;Simple and as expected!&lt;/p&gt;

&lt;p&gt;However, the preprocessor will skip &lt;code&gt;%placeholder&lt;/code&gt; and it won’t be included in the final CSS file.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why use Placeholders?
&lt;/h3&gt;

&lt;p&gt;Placeholder selectors are mainly useful when writing a SASS library where each style rule is optional.&lt;/p&gt;

&lt;p&gt;Typically, when working on your own project, it’s often better to just extend a class selector instead. But it’s good to know, as it could come in quite handy if you start working on larger-scale projects.&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;And thats it! Congratulations for making it this far 😅, this ended up being quite a lengthy article! I hope you now have more of an understanding about what you can do with SASS.&lt;/p&gt;

&lt;p&gt;In my next article, we’ll learn how to structure our SASS projects! &lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;Complete Guide to Freelancing&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%2Fq8jx3gvzvjazn8z1mbjm.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%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance" rel="noopener noreferrer"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>sass</category>
      <category>codenewbie</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Starting with SASS</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Wed, 07 Oct 2020 03:50:05 +0000</pubDate>
      <link>https://dev.to/timothyrobards/starting-with-sass-29oa</link>
      <guid>https://dev.to/timothyrobards/starting-with-sass-29oa</guid>
      <description>&lt;p&gt;&lt;strong&gt;SASS&lt;/strong&gt; (or Syntactically Awesome Style Sheets) is a tool known as a &lt;strong&gt;CSS preprocessor&lt;/strong&gt;. CSS preprocessors are scripting languages that extend the default capabilities of CSS.&lt;/p&gt;

&lt;p&gt;Other popular examples include LESS and Stylus. They are in fact all great tools to utilize when you wish to code more maintainable CSS. Especially when working with larger codebases.&lt;/p&gt;

&lt;h2&gt;
  
  
  Defining CSS Preprocessors
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;“A CSS preprocessor is a program that lets you generate CSS from the preprocessor’s own unique syntax. There are many CSS preprocessors to choose from, however most CSS preprocessors will add some features that don’t exist in pure CSS, such as mixin, nesting selector, inheritance selector, and so on. These features make the CSS structure more readable and easier to maintain”.&lt;/em&gt; — &lt;a href="https://developer.mozilla.org/en-US/"&gt;MDN&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once you’re comfortable with CSS, the next natural step is to utilize a preprocessor. The biggest advantage is not having to repeat yourself.&lt;/p&gt;

&lt;p&gt;This advantage is known as keeping your CSS &lt;strong&gt;Dry&lt;/strong&gt;, which stands for &lt;em&gt;“Don’t Repeat Yourself.”&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why use preprocessors?
&lt;/h2&gt;

&lt;p&gt;The primary advantages are as follows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cleaner code thanks to variables and nesting.&lt;/li&gt;
&lt;li&gt;Greater ease of maintenance and organisation as we can separate our files into modules.&lt;/li&gt;
&lt;li&gt;Ability to implement logic and calculation in our stylesheets.&lt;/li&gt;
&lt;li&gt;Overall improvement in workflow, which will &lt;strong&gt;save hours of development time!&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Of all the preprocessors, &lt;strong&gt;SASS&lt;/strong&gt; is by far the most popular within the developer community.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is SASS?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;SASS&lt;/strong&gt; is a scripting language that provides us with features and tools that regular CSS doesn’t have.&lt;/p&gt;

&lt;p&gt;Using SASS we can write more readable, maintainable and reusable code. Think of it as an extension that adds power and elegance to CSS.&lt;/p&gt;

&lt;p&gt;It gives us various features such as:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Variables&lt;/li&gt;
&lt;li&gt;Nesting&lt;/li&gt;
&lt;li&gt;Mixins&lt;/li&gt;
&lt;li&gt;Functions&lt;/li&gt;
&lt;li&gt;Partials &amp;amp; Imports&lt;/li&gt;
&lt;li&gt;Inheritance (Extend functionality)&lt;/li&gt;
&lt;li&gt;Control directives&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In other words, SASS helps us organize large stylesheets in a more maintainable way.&lt;/p&gt;

&lt;p&gt;And we’ll be looking into all of these features throughout my next series of articles on SASS!&lt;/p&gt;

&lt;h2&gt;
  
  
  SCSS or Sass?
&lt;/h2&gt;

&lt;p&gt;In SASS there are &lt;strong&gt;two&lt;/strong&gt; different syntaxes: &lt;strong&gt;SCSS&lt;/strong&gt; and &lt;strong&gt;Sass&lt;/strong&gt;. However after being compiled they generate similar output.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SCSS&lt;/strong&gt; (aka Sassy CSS) is the modern standard. It’s syntax is very similar to CSS in that it uses brackets and semicolons. Even normal CSS is valid in this syntax. The file extension is &lt;code&gt;.scss&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sass&lt;/strong&gt; is an older syntax that focuses on indentation to separate code blocks and newline characters to separate rules. It has the file extension &lt;code&gt;.sass&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Throughout this series, I will use &lt;strong&gt;SCSS&lt;/strong&gt; as it’s the more natural syntax (when we use SCSS we still call it SASS!).&lt;/p&gt;

&lt;p&gt;It’s also really easy to convert regular CSS to SCSS, as you can just paste in the CSS and work from there!&lt;/p&gt;

&lt;h1&gt;
  
  
  Installing SASS
&lt;/h1&gt;

&lt;p&gt;Before we can write Sass code, it needs to be installed locally. As by default, it’s not a language known to the browser.&lt;/p&gt;

&lt;p&gt;Let’s now go through the process to setup the Sass environment! So we can then write then compile our own Sass code.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; When Sass is compiled, it is converted into regular CSS code that browsers can interpret and render.&lt;/p&gt;

&lt;h2&gt;
  
  
  Environment Setup
&lt;/h2&gt;

&lt;p&gt;Before we start, you must have &lt;strong&gt;npm&lt;/strong&gt; installed on your computer, it comes bundled with &lt;a href="https://nodejs.org/en/"&gt;Node.js&lt;/a&gt;; you can install it from &lt;a href="https://nodejs.org/en/download/"&gt;here&lt;/a&gt;. Go ahead and install it if you haven’t already.&lt;/p&gt;

&lt;p&gt;If you are unsure whether you have Node.js installed or not, run &lt;code&gt;node -v&lt;/code&gt; from your terminal.&lt;/p&gt;

&lt;p&gt;If you see a version number, it’s installed!&lt;/p&gt;

&lt;p&gt;&lt;em&gt;A note on terminal:&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;If you are new to SASS, chances are you may also be new to running commands from the terminal. It’s not as daunting as it might seem! And it’s a real time-saver once you gain more experience.&lt;/p&gt;

&lt;p&gt;To open a terminal on a Windows PC, right-click the Windows Icon and select &lt;em&gt;Windows Powershell&lt;/em&gt;, if you’re on a Mac go to &lt;em&gt;Finder &amp;gt; Applications &amp;gt; Utilities &amp;gt; Terminal&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Folder Structure
&lt;/h2&gt;

&lt;p&gt;Let’s create our project folders! They will be structured like so:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sass"&gt;&lt;code&gt;&lt;span class="nt"&gt;sass-project&lt;/span&gt;
   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="nt"&gt;-&lt;/span&gt; &lt;span class="nt"&gt;sass&lt;/span&gt;
   &lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="nt"&gt;-&lt;/span&gt; &lt;span class="nt"&gt;css&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To create this structure, open terminal and change to the folder you wish to install the sass project into (via the cd command).&lt;/p&gt;

&lt;p&gt;Then run the following commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;mkdir sass-project
cd sass-project
mkdir -p sass css
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  File Structure
&lt;/h2&gt;

&lt;p&gt;You will need an &lt;em&gt;index.html&lt;/em&gt; and &lt;em&gt;main.scss&lt;/em&gt; in this folder.&lt;/p&gt;

&lt;p&gt;To create these files, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;touch index.html
cd sass
touch main.scss
cd ..
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You’ll also need a default CSS stylesheet for the SASS to compile into:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd css
touch style.css
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Open up your &lt;em&gt;index.html&lt;/em&gt; and paste in the following code:&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;title&amp;gt;&lt;/span&gt;Index 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;”css/style.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;/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;This is just our boilerplate code with the stylesheet connected!&lt;/p&gt;

&lt;h2&gt;
  
  
  Initializing our Project Directory
&lt;/h2&gt;

&lt;p&gt;All projects that use npm need to be initialized. To do this, ensure you’re still in the sass-project folder and run the following 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 -y
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will create a &lt;strong&gt;package.json&lt;/strong&gt; file for our project. We’ll be learning more about the configuration of this file later in the course!&lt;/p&gt;

&lt;h2&gt;
  
  
  Install node-sass
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;node-sass&lt;/strong&gt; is the library which allows us to compile &lt;code&gt;.scss&lt;/code&gt; to &lt;code&gt;.css&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Run the following command to install node-sass as &lt;em&gt;dev dependency&lt;/em&gt;.&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 node-sass --save-dev
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; A &lt;strong&gt;dev dependency&lt;/strong&gt; is only used in the build phase of our project. It’s not included at runtime.&lt;/p&gt;

&lt;h2&gt;
  
  
  Compiling Sass Code to CSS
&lt;/h2&gt;

&lt;p&gt;Next, we need to create an &lt;em&gt;npm script&lt;/em&gt; to run the compilation.&lt;/p&gt;

&lt;p&gt;Add this script inside the script section of our previously created &lt;strong&gt;package.json&lt;/strong&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"compile-sass": "node-sass sass/main.scss css/style.css"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Don’t forget to separate each script with a comma!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;We have here specified &lt;strong&gt;main.scss&lt;/strong&gt; as our main Sass file and &lt;strong&gt;style.css&lt;/strong&gt; as the compiled CSS file.&lt;/p&gt;

&lt;p&gt;To compile our SASS code into CSS, all we need to do is run:&lt;br&gt;
&lt;/p&gt;

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

&lt;/div&gt;



&lt;h2&gt;
  
  
  Live Reload
&lt;/h2&gt;

&lt;p&gt;Let’s also add a live reload to our project! To do this run the following to install globally:&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 live-server -g
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, make sure you’re still in the Sass project folder, and run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;live-server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And just like that, you’ve got a pretty neat dev environment with your project running locally on HTTP.&lt;/p&gt;

&lt;p&gt;You’ll need to keep &lt;code&gt;live-server&lt;/code&gt; and &lt;code&gt;npm run compile-sass&lt;/code&gt; running in two separate terminal windows.&lt;/p&gt;

&lt;p&gt;So we now have the project environment all set up on the local machine :)&lt;/p&gt;

&lt;p&gt;That's all for today! In the next one, I'll be taking a look at the features of SASS in detail.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>sass</category>
      <category>codenewbie</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Getting started with BEM</title>
      <dc:creator>Timothy Robards</dc:creator>
      <pubDate>Sun, 27 Sep 2020 01:55:35 +0000</pubDate>
      <link>https://dev.to/timothyrobards/getting-started-with-bem-4m93</link>
      <guid>https://dev.to/timothyrobards/getting-started-with-bem-4m93</guid>
      <description>&lt;p&gt;If you’re unfamiliar with BEM, its simple to get started! It’ll add a ton of structure, scalability &amp;amp; robustness to an otherwise un-BEM’d stylesheet.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is BEM?
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;BEM — &lt;strong&gt;B&lt;/strong&gt;lock &lt;strong&gt;E&lt;/strong&gt;lement &lt;strong&gt;M&lt;/strong&gt;odifier is a methodology that helps you to create reusable components and code sharing in front-end development — &lt;a href="http://getbem.com/"&gt;getbem.com&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If you’ve ever seen class names like &lt;code&gt;form__submit--disabled&lt;/code&gt; that’s BEM in action. The use of this methodology allows us to create a more consistent coding structure in both our HTML and CSS/Sass files.&lt;/p&gt;

&lt;h2&gt;
  
  
  How do I BEM?
&lt;/h2&gt;

&lt;p&gt;All you need to do is name your classes in accordance with the BEM naming convention. This article provides a quick run down..&lt;/p&gt;

&lt;h2&gt;
  
  
  Block
&lt;/h2&gt;

&lt;p&gt;The &lt;em&gt;block&lt;/em&gt; is the container or context where the elements are situated. It should be able to stand alone and still make sense in the overall structure of your code. A typical layout often includes a header, sidebar, main content area &amp;amp; footer, each of these would be considered blocks:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Farxu3o93uf7bvp8epas4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Farxu3o93uf7bvp8epas4.png" alt="Alt Text" width="677" height="595"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So blocks are standalone elements that form the root of your code structure, in this example we have &lt;code&gt;.header, .sidebar, .main&lt;/code&gt; and &lt;code&gt;.footer&lt;/code&gt;. They have no dependencies on any other blocks/elements on the page.&lt;/p&gt;

&lt;p&gt;Contained within each block are elements..&lt;/p&gt;

&lt;h2&gt;
  
  
  Element
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Elements&lt;/em&gt; are parts of a block which have no semantic meaning outside of the block. As each element is semantically tied to its block. The syntax is as follows:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.block__element{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Elements are written using the block name, connected by two underscores.&lt;/p&gt;

&lt;p&gt;So for example, our header might contain a logo, nav bar, and search box. These element classes would be named as follows:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.header__logo{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.header__navbar{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.header__searchbox{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Already you can see the beginnings of a more readable code structure. The importance of convention increases dramatically when working on larger projects, especially when working collaboratively.&lt;/p&gt;

&lt;h2&gt;
  
  
  Modifiers
&lt;/h2&gt;

&lt;p&gt;A &lt;em&gt;modifier&lt;/em&gt; is a flag on a block or an element which is used to change appearance, behavior or state. It’s where the one of the great strengths of BEM shines through; modularity. By using modifiers, you can extend a block or element to make it repeatable. This is a big win as it facilitates code reuse and component driven coding. The syntax is like so:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.block--modifier{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.block__element--modifier{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;A double hyphen &lt;code&gt;--&lt;/code&gt; is added after the block or element followed by the modifier name.&lt;/p&gt;

&lt;p&gt;So take our &lt;code&gt;.header__navbar{}&lt;/code&gt; element. We may wish to create a modifier for a secondary navbar, which extends the element with additional styles, like so..&lt;/p&gt;

&lt;p&gt;&lt;code&gt;.header__navbar--secondary{}&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;If your styles are basically the same, using Sass you can simply extend from the parent element and then add the modifiers as required. See the below example, which changes the background color of the secondary navbar..&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="nc"&gt;.header__navbar&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;list-style-type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#ff0000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1rem&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;text-transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;uppercase&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.header__navbar--secondary&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="err"&gt;@extend&lt;/span&gt; &lt;span class="err"&gt;.header__navbar;&lt;/span&gt;
  &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#ff4500&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;And that’s it! The modifier styles will override the parent. Your code will be much more concise and easier to work with.&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping up
&lt;/h2&gt;

&lt;p&gt;BEM is a simple way to add structure and hierarchy to your front-end development. I hope this brief guide is enough to get you up and running! As always, there’s much more to explore. Check out the following:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://en.bem.info/methodology/"&gt;Bem.info: Methodology&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://seesparkbox.com/foundry/bem_by_example"&gt;BEM by example&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://bem.info/"&gt;BEM Homepage&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;em&gt;&lt;strong&gt;Are you ready to turn your dev skills into a freelance business?&lt;/strong&gt; Whether you're completely new to freelancing or are looking to level up your existing skills. I'll teach you everything you need to know to become a successful freelancer!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Get started today with my &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;Complete Guide to Freelancing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq8jx3gvzvjazn8z1mbjm.png" alt="Complete Guide to Freelancing package" width="800" height="373"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Available now at 👉 &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;https://easeout.gumroad.com/l/freelance&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A little about me..
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Tim! 👋 I'm a freelance business owner, web developer &amp;amp; author. &lt;/p&gt;

&lt;p&gt;I teach both new and experienced freelancers how to &lt;a href="https://easeout.gumroad.com/l/freelance"&gt;build a sustainable and successful freelancing business&lt;/a&gt;. If you'd like to read more of my articles, check them out on &lt;a href="//www.easeout.co"&gt;my blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Thanks for reading 🎉&lt;/p&gt;

</description>
      <category>css</category>
      <category>codenewbie</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
