<?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: Ilesanmi Temitope</title>
    <description>The latest articles on DEV Community by Ilesanmi Temitope (@itope84).</description>
    <link>https://dev.to/itope84</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%2F226430%2F11611747-c5c9-4743-a906-10559a109fbc.png</url>
      <title>DEV Community: Ilesanmi Temitope</title>
      <link>https://dev.to/itope84</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/itope84"/>
    <language>en</language>
    <item>
      <title>Tips to supercharge your job search</title>
      <dc:creator>Ilesanmi Temitope</dc:creator>
      <pubDate>Sun, 17 Jul 2022 19:43:48 +0000</pubDate>
      <link>https://dev.to/itope84/tips-to-supercharge-your-job-search-no5</link>
      <guid>https://dev.to/itope84/tips-to-supercharge-your-job-search-no5</guid>
      <description>&lt;p&gt;Recently, I’ve had to give several people tips on how to improve their job search. Some of these things I’ve always assumed were either common knowledge or just not worth writing about, hence why I have delayed until now.&lt;/p&gt;

&lt;p&gt;Trying to find a new job is the ghetto, really. It’s so frustrating and we’ve all been there (unless you’re a trust fund kid and never had to apply for a job, in which case, I’m so jealous of you). There are so many challenges, including:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Finding the right job to apply to. There are thousands of jobs with any google search or on your favourite job platform and you can’t find the ones that match your exact needs&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Crafting the right application: “Is my resume perfect?”, “Does this cover letter make any sense?”, “I’ve sent a thousand applications and none of these companies are replying me, why aren’t they replying me? Do they hate me?”. These are just some of the questions you probably ask while sending out applications&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;And finally, when they do get back to you, you still need to pass the interviews, all of the hundred stages 🤷🏻‍♂️&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In this article, we will address the first challenge: finding the right jobs that match what you’re looking for. Before I proceed, in case you’ve already found the perfect job and would like to answer the second question, &lt;a href="https://dev.toundefined"&gt;Dillion Megida&lt;/a&gt; has a really good &lt;a href="https://dillionmegida.com/p/cover-letter-template/"&gt;Cover Letter template&lt;/a&gt; that I’ve heard is perfect. You can check it out and modify it to suit the job you’re applying for.&lt;/p&gt;

&lt;h3&gt;
  
  
  Job boards, duh
&lt;/h3&gt;

&lt;p&gt;Well, the first stop on applying for a new job is often job boards. And there are many job boards depending on what you’re looking for. For the sake of brevity, I’ll list some job boards based on what they’re best for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Looking for a relocation job to the UK: &lt;a href="https://app.otta.com/"&gt;Otta.com&lt;/a&gt; seems to be the best option I’ve come across&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Looking for a relocation job to Europe: &lt;a href="https://app.otta.com/"&gt;Otta.com&lt;/a&gt;, &lt;a href="https://relocate.me"&gt;https://relocate.me&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Looking for a (usually high paying) remote role at top startups worldwide: &lt;a href="https://startup.jobs"&gt;https://startup.jobs&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;For jobs specific to a particular technology, you can find job boards for that tech, such as &lt;br&gt;
&lt;a href="https://vuejobs.com/"&gt;https://vuejobs.com/&lt;/a&gt;, &lt;a href="https://vuetifyjs.com/en/resources/jobs-for-vue/"&gt;https://vuetifyjs.com/en/resources/jobs-for-vue/&lt;/a&gt; for VueJs related jobs.&lt;br&gt;
&lt;a href="https://reactjobsboard.com/"&gt;https://reactjobsboard.com/&lt;/a&gt; For ReactJs jobs.&lt;br&gt;
You get the gist, you can find one or more of these websites for your technology. I’ll include a couple more links in the Appendix and you can add others in the comments if you want.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Pro Tip&lt;/strong&gt;: Even if it’s possible to send applications on these job boards, I’d recommend not doing so. But rather, find the job on the company’s website and apply directly through their recruitment portal. They will monitor their own hiring board, plus you will be able to fill in their requirements as they want it. Some companies hire directly on Otta.com, so in those cases, Otta does make it easier to apply in bulk with a single profile, but asides that, I’ve found that applying on the company’s job portal directly yields better results&lt;/p&gt;

&lt;p&gt;In addition, to the above, if you’re applying on Otta, they give you the power to restrict the jobs you see through a bunch of filters. Don’t be afraid to use those filters. Job application is a game of numbers, but at the same time you don’t want to be applying to jobs you don’t stand a chance for, or jobs you might not like if you get them. This applied to all job boards really, &lt;strong&gt;don’t be afraid to filter&lt;/strong&gt;! Make sure the shots you attempt are shots you actually have a chance at making. Otherwise, you’d be wasting precious time, time you could spend applying to jobs that are a better match for you.&lt;/p&gt;

&lt;h3&gt;
  
  
  Google Search
&lt;/h3&gt;

&lt;p&gt;While searching on dedicated job boards will yield the best results, you might be missing out on other jobs that don’t make it to the popular job boards. For example, if you’re a junior developer, or write a fringe technology like Flutter 👀, you might be finding it difficult to get enough quality jobs to apply to on these job boards. That’s where a well-constructed google search comes in.&lt;/p&gt;

&lt;p&gt;You can type in “Frontend developer jobs” on google and you’d get thousands of results. However, our goal is to find jobs that are tailored to our needs. The good news is you can practically tell Google everything you want in a job, using advanced google search filters and you’d get a well filtered result. Now, this isn’t exactly a “Google search tutorial article”, I’m sure you can find hundreds of those online. Rather, I’d give some examples of searches you could be making.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Target recruitment portals&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A google search technique I’ve used a lot is to target recruitment portals that companies often use. These include: lever.co, breezy.hr, greenhouse.io, workable.com (and a lot more, these are just the most popular). What I do is combine all of these into one google search (you can split them if you want) and add a few keywords. The advantage of this is, companies that use these recruitment platforms are typically serious about the recruitment (versus the jobs simply posted on Linkedin or Indeed), because these platforms aren’t free (or cheap, though I don’t know what they cost). Hence, they’re less likely to “air” you, than those who simply post on Linkedin or indeed.&lt;/p&gt;

&lt;p&gt;An example Query is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;backend developer (site:lever.co OR site:breezy.hr OR site:workable.com OR site:greenhouse.io)&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The query above will only show backend developer jobs that appear on one of those recruitment portals above.&lt;br&gt;
NB: The site:lever.co means “Only show me results from this site lever.co”. The “OR” keyword is used to add multiple conditions, kind of like a logical condition you’d put in an if-else (Nobody told you you’d find coding jobs by coding your google search eh?). Also, see how I grouped all the conditions together in a parentheses, this allows google to separate it from the rest of my query, and not apply the OR to “backend developer” as well.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Add your keywords&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;(I started this numbered list because numbering things seemed cool, but I’m starting to think it wasn’t a great idea).&lt;/p&gt;

&lt;p&gt;Remember when I said “apply filters on job boards”? Well, it’s all the more important here. A google search as you can imagine, will yield lots of results. Including many you don’t need. So add more filters to your search.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;WARNING&lt;/strong&gt;: Too many filters, or an overly complicated query will probably yield zero results. But hey, you can go back and edit it till it gives you what you want. Anyway, here are some examples I’ve used in the past&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;(junior OR intern) frontend developer (vue OR react OR javascript) (intitle:remote OR intext:remote) -site:linkedin.com -site:totaljobs.com&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Okay, ngl, I’ve not used that one before, but it seems like a cool idea. The query above will show results for junior or intern frontend developers, with “remote” in the title or in the body of the page. Adding a “-” before any text will exclude it from the results. So the search above will &lt;strong&gt;exclude linkedIn and totaljobs&lt;/strong&gt; which for personal reasons I find to be annoying places to find jobs. So you can also include (exclude) sites you hate.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;backend (Python OR Go OR typescript OR Node) (intext:London OR intitle:London) (site:lever.co OR site:breezy.hr OR workable.com)&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This one I’ve definitely used. you can read the query and guess what it searches for.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Additional tip&lt;/strong&gt;: Surround essential text in quotes to tell google, “whatever you do, this text must be in the result”.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;backend (Python OR Go OR typescript OR Node) (intext:London OR intitle:London) &lt;strong&gt;(“visa” OR “relocation”)&lt;/strong&gt; (site:lever.co OR site:breezy.hr OR workable.com)&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This query will is the same as the earlier one, except this will only show jobs that specifically mention visa or relocation in their description. I don’t advise using this solely, many companies that sponsor visa might not include it in their description as I’ve found.&lt;/p&gt;

&lt;h3&gt;
  
  
  Honorable Mention
&lt;/h3&gt;

&lt;p&gt;**Twitter: **You can find just about everything on Twitter if you look hard enough. Applying the right search on twitter will show you some company executives posting their jobs on Twitter&lt;/p&gt;

&lt;p&gt;**LinkedIn: **Okay fine, I’ve been dissing LinkedIn all day. But it’s still one of the best sources for job hunting and connecting with recruiters. I wouldn’t use it as my primary source of job hunting (unless you like disappointments), but definitely watch out for Tech leads and C-suite executives with a “hiring” badge and posting about their open positions. You might even be able to cold-DM them to shoot your shot&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Indeed&lt;/strong&gt;, &lt;strong&gt;Angel.co&lt;/strong&gt;, &lt;strong&gt;Glassdoor&lt;/strong&gt; are still great places to look when you’re bored or the intro of your favourite Netflix movie is playing and you need to get out a quick application.&lt;/p&gt;

&lt;p&gt;**RIP: Stackoverflow Jobs 😔. **Used to be one of the best resources, but has been killed because it apparently doesn’t make enough money.&lt;/p&gt;

&lt;h3&gt;
  
  
  What Next
&lt;/h3&gt;

&lt;p&gt;Like we said earlier, you still need to have a great resume, and a great cover letter. I referenced a cool cover letter template you can use above. maybe someday we’ll talk about how to improve your resume, but here are are a few tips before we close:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Use Google docs to create your resume. It’s better than most fancy resume tools out there. Especially if you want an ATS to read your resume well, also you can see your edit history and use that to maintain different versions&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Check out &lt;a href="http://resumeworded.com"&gt;resumeworded.com&lt;/a&gt;, it’s a tool you can use to analyze your resume and see improvement areas (for free too!)&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Until next time, may the force be with you, or whatever.&lt;/p&gt;

&lt;p&gt;This post originally appeared in &lt;a href="https://medium.com/@psicliffs/tips-to-supercharge-your-job-search-a0794eacf9ed"&gt;https://medium.com/@psicliffs/tips-to-supercharge-your-job-search-a0794eacf9ed&lt;/a&gt;&lt;/p&gt;

</description>
      <category>jobsearch</category>
      <category>googlesearch</category>
      <category>jobboards</category>
    </item>
    <item>
      <title>The hitchhiker's guide to reusable Icons and SVG sprite generation</title>
      <dc:creator>Ilesanmi Temitope</dc:creator>
      <pubDate>Tue, 20 Apr 2021 16:59:16 +0000</pubDate>
      <link>https://dev.to/itope84/the-hitchhiker-s-guide-to-reusable-icons-and-svg-sprite-generation-51e2</link>
      <guid>https://dev.to/itope84/the-hitchhiker-s-guide-to-reusable-icons-and-svg-sprite-generation-51e2</guid>
      <description>&lt;p&gt;Tell me if this sounds familiar: You have a bunch of icons to use in your awesome web project. You don't want to use an icon library (Font awesome, material icons) probably because they're from different sources, or you just want to avoid the huge size that comes with libraries. So you head to icomoon.io (or similar) and upload all of your icons and then generate and download the icon-font set (or SVG sprite) generated for you and you go ahead to use that in your project.&lt;/p&gt;

&lt;p&gt;The problem is, in 2 weeks' time, your designer comes along with a bunch of other icons you have to add and you have to upload these new ones, a JSON file from the one you generated earlier, and then generate a new set. This can get pretty monotonous and annoying, and there are a couple of ways things can go wrong; oh and did I mention, boring and monotonous.&lt;/p&gt;

&lt;p&gt;In this article, we're going to look at:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;how we can automate that process. Such that, whenever you need to add a new icon, you just run a command and your new SVG Sprite is generated for you&lt;/li&gt;
&lt;li&gt;creating a reusable component to use the generated icons in the SVG Sprite.&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;This article shows how to create reusable SVG icons using SVG sprites (you should be using (controversially) SVG sprites as opposed to icon fonts. Here's why: &lt;a href="https://css-tricks.com/icon-fonts-vs-svg/" rel="noopener noreferrer"&gt;https://css-tricks.com/icon-fonts-vs-svg/&lt;/a&gt;, &lt;a href="https://www.sitepoint.com/icon-fonts-vs-svg-debate/" rel="noopener noreferrer"&gt;https://www.sitepoint.com/icon-fonts-vs-svg-debate/&lt;/a&gt;). However, the same principles can be applied to generating and using icon-fonts as well.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  Creating an SVG sprite
&lt;/h2&gt;

&lt;p&gt;The approach we’ll be using in this article allows you to easily add any new SVGs to an &lt;code&gt;icons&lt;/code&gt; folder, run a script to generate your sprite, and create a reusable component to make these icons easy to use. This approach also allows you to version control your icons and modify or roll back as you need.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Get a bunch of icons in an svg folder&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Let’s create a &lt;code&gt;src/icons&lt;/code&gt; - or whatever fits your project structure - folder where we will place all our SVG icons.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxhjn3ii5hyo67yt70xvt.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%2Fxhjn3ii5hyo67yt70xvt.png" alt="Folder structure"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create the SVG sprite&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Next, to create the svg sprite, we need to install &lt;code&gt;grunt&lt;/code&gt; and &lt;code&gt;grunt-svgstore&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;yarn add &lt;span class="nt"&gt;--dev&lt;/span&gt; grunt grunt-svgstore
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, to create our grunt task, create a Gruntfile.js file in the root folder of your project and put the following contents in it&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;module&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;exports&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;grunt&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// Project configuration.&lt;/span&gt;
  &lt;span class="nx"&gt;grunt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;initConfig&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="c1"&gt;// PLUGINS CONFIG&lt;/span&gt;
    &lt;span class="na"&gt;svgstore&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="na"&gt;options&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;prefix&lt;/span&gt;&lt;span class="p"&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;// This will prefix each &amp;lt;g&amp;gt; ID in the generated SVG. You do not need it, but you can add it to avoid conflicting icon names with any other SVG sprites&lt;/span&gt;
        &lt;span class="na"&gt;includedemo&lt;/span&gt;&lt;span class="p"&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;// Do you want to generate a demo html file showing how the icons are used?&lt;/span&gt;
      &lt;span class="p"&gt;},&lt;/span&gt;
      &lt;span class="na"&gt;default&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;files&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="c1"&gt;// destination_file (for the sprite): source_files (array of matchers pointing to your svg files)&lt;/span&gt;
          &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;src/assets/svgs/icon-sprite.svg&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="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;src/icons/*.svg&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="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;});&lt;/span&gt;

  &lt;span class="nx"&gt;grunt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;loadNpmTasks&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;grunt-svgstore&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

  &lt;span class="c1"&gt;// Default task(s).&lt;/span&gt;
  &lt;span class="nx"&gt;grunt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;registerTask&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;default&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;svgstore&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We have registered the &lt;code&gt;svgstore&lt;/code&gt; task as default, hence running &lt;code&gt;grunt&lt;/code&gt; should run the &lt;code&gt;svgstore&lt;/code&gt; task.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;NOTE:&lt;/strong&gt; The destination file is the generated SVG file path, we have set this to &lt;code&gt;src/assets/svgs/icon-sprite.svg&lt;/code&gt;. Feel free to change this to any valid path in your code where you feel more comfortable have the sprite generated. The &lt;strong&gt;source_files&lt;/strong&gt; regex matches all svg files in the &lt;code&gt;src/icons&lt;/code&gt; folder we created earlier&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Check the &lt;a href="https://github.com/FWeinb/grunt-svgstore" rel="noopener noreferrer"&gt;grunt-svgstore&lt;/a&gt; documentation for more configuration options.&lt;/p&gt;

&lt;p&gt;Finally, add the script to your package.json&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="err"&gt;...&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="nl"&gt;"scripts"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="err"&gt;...&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"generate-sprite"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"grunt"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you can run &lt;code&gt;yarn generate-sprite&lt;/code&gt; to generate your svg sprite. A demo HTML file will also be generated alongside and you can open up the file to make sure that every icon looks right.&lt;/p&gt;

&lt;h3&gt;
  
  
  Inserting the SVG Sprite
&lt;/h3&gt;

&lt;p&gt;To use our newly generated sprite, we need to insert it in the &lt;code&gt;&amp;lt;body&amp;gt;&lt;/code&gt; tag. We want to insert it as the uppermost item in the DOM. &lt;/p&gt;

&lt;p&gt;One way to insert this would be to copy the entire contents of &lt;code&gt;custom-icons.svg&lt;/code&gt; and paste it in your index.html or layout component. But this wouldn’t exactly be ideal, now would it (especially if you’re using React or Vue or any other component-based framework that uses &lt;em&gt;webpack&lt;/em&gt; to load files). &lt;/p&gt;

&lt;p&gt;An alternative, more ideal approach would be to use webpack to load the SVG file as a component. &lt;br&gt;
&lt;strong&gt;Using Vue:&lt;/strong&gt; simply install and configure &lt;a href="https://www.npmjs.com/package/vue-svg-loader" rel="noopener noreferrer"&gt;&lt;code&gt;vue-svg-loader&lt;/code&gt;&lt;/a&gt;. Then create the CustomSprite component.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight vue"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;&lt;/span&gt;&lt;span class="k"&gt;template&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"display: none;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;icon-sprite&lt;/span&gt; &lt;span class="nt"&gt;/&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;/&lt;/span&gt;&lt;span class="k"&gt;template&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;

&lt;span class="nt"&gt;&amp;lt;&lt;/span&gt;&lt;span class="k"&gt;script&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;IconSprite&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;assets/svgs/icon-sprite.svg&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;components&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;IconSprite&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="nt"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="k"&gt;script&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Using React:&lt;/strong&gt; if your project is built with create-react-app and you have not yet ejected, then you don’t need to install anything, simply create the component below.&lt;/p&gt;

&lt;p&gt;If your project has already been ejected, or you’re using &lt;code&gt;NextJs&lt;/code&gt; or something similar that allows you to configure webpack, you might want to take a look at &lt;a href="https://react-svgr.com/docs/webpack/" rel="noopener noreferrer"&gt;&lt;code&gt;@svgr/webpack&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Create the CustomSprite component like such:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;ReactComponent&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="nx"&gt;IconSprite&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;assets/svgs/icon-sprite.svg&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;CustomSprite&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt; &lt;span class="na"&gt;style&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;none&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;IconSprite&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;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;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;CustomSprite&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Note that the component is wrapped in a hidden div (and it is styled inline). That’s because we don’t want to show the sprite on the page at all (the inline styling is to prevent a flash before css loads).&lt;/p&gt;

&lt;p&gt;Now you can insert your CustomSprite component in the root of the page&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
  // your custom icon sprite
  &lt;span class="nt"&gt;&amp;lt;custom-sprite&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  ...
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Using individual icons from the sprite.
&lt;/h3&gt;

&lt;p&gt;Now we need to use our newly minted icon sprite to add any icons on the page.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;svg&lt;/span&gt;
  &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"icon"&lt;/span&gt;
  &lt;span class="na"&gt;aria-label=&lt;/span&gt;&lt;span class="s"&gt;"Rotate left"&lt;/span&gt;
&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;use&lt;/span&gt; &lt;span class="na"&gt;xlink:href=&lt;/span&gt;&lt;span class="s"&gt;"#rotate-left"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/svg&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We're almost there! But this seems like an awful lot of code to write just to use a rotate-left icon. So we're going to make it into a component instead.&lt;/p&gt;

&lt;h3&gt;
  
  
  Create a reusable SvgIcon component
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Vue:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight vue"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;&lt;/span&gt;&lt;span class="k"&gt;template&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;svg&lt;/span&gt;
  &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"icon"&lt;/span&gt;
  &lt;span class="na"&gt;:aria-label=&lt;/span&gt;&lt;span class="s"&gt;"label"&lt;/span&gt;
&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;use&lt;/span&gt; &lt;span class="na"&gt;:xlink:href=&lt;/span&gt;&lt;span class="s"&gt;"`#$&lt;/span&gt;{icon}`" /&amp;gt;
&lt;span class="nt"&gt;&amp;lt;/svg&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="k"&gt;template&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;&lt;/span&gt;&lt;span class="k"&gt;script&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;props&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;icon&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="na"&gt;label&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;String&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;default&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;null&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="nt"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="k"&gt;script&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;React&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react&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;SvgIcon&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;({&lt;/span&gt;&lt;span class="nx"&gt;icon&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;label&lt;/span&gt;&lt;span class="p"&gt;})&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;svg&lt;/span&gt;
      &lt;span class="na"&gt;class&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"icon"&lt;/span&gt;
      &lt;span class="na"&gt;aria-label&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;label&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;use&lt;/span&gt; &lt;span class="na"&gt;xlink&lt;/span&gt;&lt;span class="err"&gt;:&lt;/span&gt;&lt;span class="na"&gt;href&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="s2"&gt;`#&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;icon&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;svg&lt;/span&gt;&lt;span class="p"&gt;&amp;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;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;SvgIcon&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it! You can now use your icons by using your component with the icon name anywhere.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight vue"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;svg-icon&lt;/span&gt; &lt;span class="na"&gt;icon=&lt;/span&gt;&lt;span class="s"&gt;"rotate-left"&lt;/span&gt; &lt;span class="na"&gt;label=&lt;/span&gt;&lt;span class="s"&gt;"rotate-left icon"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Or React&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight jsx"&gt;&lt;code&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;SvgIcon&lt;/span&gt; &lt;span class="na"&gt;icon&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"rotate-left"&lt;/span&gt; &lt;span class="na"&gt;label&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"rotate-left icon"&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Feel free to modify the process to suit your needs. Now when you have new icons, all you have to do is  &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add them to your &lt;code&gt;src/icons&lt;/code&gt; folder&lt;/li&gt;
&lt;li&gt;Run &lt;code&gt;npm run custom-icons&lt;/code&gt; or &lt;code&gt;yarn custom-icons&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;and your new icons will be added to the sprite.&lt;/p&gt;

&lt;p&gt;I hope this helps, if you run into any troubles, please feel free to let me know.&lt;/p&gt;

</description>
      <category>svg</category>
      <category>sprites</category>
      <category>icons</category>
      <category>a11y</category>
    </item>
  </channel>
</rss>
