{"id":8418,"date":"2018-03-27T12:53:02","date_gmt":"2018-03-27T19:53:02","guid":{"rendered":"http:\/\/blog.mozilla.org\/addons\/?p=8418"},"modified":"2018-03-27T12:53:02","modified_gmt":"2018-03-27T19:53:02","slug":"improving-add-ons-linter","status":"publish","type":"post","link":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/","title":{"rendered":"Improving the Add-ons Linter"},"content":{"rendered":"<p>For the last five years, Mozilla has participated in the <a href=\"https:\/\/www.outreachy.org\/\">Outreachy<\/a> program to provide three-month internships for people from groups traditionally underrepresented in tech. From December 2017 &#8211; March 2018, interns <a href=\"https:\/\/mozillians.org\/en-US\/u\/ravneette\/\">Ravneet Kaur<\/a> and <a href=\"https:\/\/mozillians.org\/en-US\/u\/hameleonka\/\">Natalia Milavanova<\/a> worked under the guidance of <a href=\"https:\/\/github.com\/EnTeQuAk\">Christopher Grebs<\/a> and <a href=\"https:\/\/mozillians.org\/en-US\/u\/luca\/\">Luca Greco<\/a> to improve the add-ons linter.<\/p>\n<p>The <a href=\"https:\/\/github.com\/mozilla\/addons-linter\">add-ons linter<\/a> is a tool that warns of potential problems within an extension\u2019s code. Developers can use the <a href=\"https:\/\/developer.mozilla.org\/Add-ons\/WebExtensions\/Getting_started_with_web-ext\">web-ext command line tool<\/a> to run the linter locally to check for potential issues during development, and <a href=\"https:\/\/addons.mozilla.org\">addons.mozilla.org<\/a> (AMO) uses it to validate an extension during the submission process.<\/p>\n<p>Ravneet\u2019s internship project was to land a localization feature to the add-ons linter. By offering the option to see errors and warnings in multiple languages, the linter can be more accessible to add-on developers who prefer to work with non-English languages. Ravneet successfully adapted <a href=\"https:\/\/pontoon.mozilla.org\/\">Pontoon\u2019s<\/a> localization method for the add-ons linter and extracted about 19,000 lines of code in the process.<\/p>\n<p>Outreachy internships are a great way to gain real-world experience working with distributed teams and grow software development skills. \u201cThis project was the first time I was introduced to the idea of bundling code using technologies like <a href=\"https:\/\/webpack.js.org\/\">webpack<\/a>,\u201d Ravneet says. \u201cAfter going through its documentation and reading blog posts about it, I was fascinated about the idea of bundling code together and building small, minimalistic projects in production, while having a wide variety of maintainable files and folders in the project\u2019s source.\u201d<\/p>\n<p>Natalia tackled a different challenge: improve the linter\u2019s validation by rewriting a large chunk of the code and test suite into async functions. For a long time, the linter\u2019s code had been cumbersome to work with. After refactoring the code, Natalia removed approximately 3% of the code. Luca notes, \u201cThanks to Natalia\u2019s hard work on this this project, our ability to debug and handle errors in the add-ons linter has been greatly improved. It\u2019s now easier to read and understand the sources, and prepare for the changes that are coming next.\u201d<\/p>\n<p>Thank you for all of your contributions, Natalia and Ravneet! We look forward to seeing your future accomplishments.<\/p>\n<p>If you\u2019re interested in learning more about Outreachy, please visit their <a href=\"https:\/\/www.outreachy.org\/\">website<\/a>. While you\u2019re at it, check out our own Outreachy alum <a href=\"https:\/\/mozillians.org\/en-US\/u\/sj\/\">Shubheksha Jalan\u2019s<\/a> <a href=\"https:\/\/medium.freecodecamp.org\/outreachy-what-how-why-4fb60d10a228\">blog post<\/a> about her experience applying to the program.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For the last five years, Mozilla has participated in the Outreachy program to provide three-month internships for people from groups traditionally underrepresented in tech. From December 2017 &#8211; March 2018, &hellip; <a class=\"go\" href=\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/\">Read more<\/a><\/p>\n","protected":false},"author":1405,"featured_media":8419,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[278890,121],"tags":[287737],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Improving the Add-ons Linter - Mozilla Add-ons Community Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Caitlin Neiman\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/\",\"url\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/\",\"name\":\"Improving the Add-ons Linter - Mozilla Add-ons Community Blog\",\"isPartOf\":{\"@id\":\"https:\/\/blog.mozilla.org\/addons\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg\",\"datePublished\":\"2018-03-27T19:53:02+00:00\",\"dateModified\":\"2018-03-27T19:53:02+00:00\",\"author\":{\"@id\":\"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/d42e525583ec49a90da7806934fd533f\"},\"breadcrumb\":{\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage\",\"url\":\"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg\",\"contentUrl\":\"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg\",\"width\":279,\"height\":279,\"caption\":\"A picture of a woman with a red shirt and glasses looking just off to the left of the camera.\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/blog.mozilla.org\/addons\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Improving the Add-ons Linter\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/#website\",\"url\":\"https:\/\/blog.mozilla.org\/addons\/\",\"name\":\"Mozilla Add-ons Community Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/blog.mozilla.org\/addons\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/d42e525583ec49a90da7806934fd533f\",\"name\":\"Caitlin Neiman\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/022ba856a87c8f40739b7ef2fdcdf33c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/022ba856a87c8f40739b7ef2fdcdf33c?s=96&d=mm&r=g\",\"caption\":\"Caitlin Neiman\"},\"description\":\"Add-ons Community Manager at Mozilla.\",\"url\":\"https:\/\/blog.mozilla.org\/addons\/author\/cneimanmozilla-com\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Improving the Add-ons Linter - Mozilla Add-ons Community Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/","twitter_misc":{"Written by":"Caitlin Neiman","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/","url":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/","name":"Improving the Add-ons Linter - Mozilla Add-ons Community Blog","isPartOf":{"@id":"https:\/\/blog.mozilla.org\/addons\/#website"},"primaryImageOfPage":{"@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage"},"image":{"@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage"},"thumbnailUrl":"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg","datePublished":"2018-03-27T19:53:02+00:00","dateModified":"2018-03-27T19:53:02+00:00","author":{"@id":"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/d42e525583ec49a90da7806934fd533f"},"breadcrumb":{"@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#primaryimage","url":"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg","contentUrl":"https:\/\/blog.mozilla.org\/addons\/files\/2018\/03\/kaur_ravneet.jpg","width":279,"height":279,"caption":"A picture of a woman with a red shirt and glasses looking just off to the left of the camera."},{"@type":"BreadcrumbList","@id":"https:\/\/blog.mozilla.org\/addons\/2018\/03\/27\/improving-add-ons-linter\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/blog.mozilla.org\/addons\/"},{"@type":"ListItem","position":2,"name":"Improving the Add-ons Linter"}]},{"@type":"WebSite","@id":"https:\/\/blog.mozilla.org\/addons\/#website","url":"https:\/\/blog.mozilla.org\/addons\/","name":"Mozilla Add-ons Community Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/blog.mozilla.org\/addons\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/d42e525583ec49a90da7806934fd533f","name":"Caitlin Neiman","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/blog.mozilla.org\/addons\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/022ba856a87c8f40739b7ef2fdcdf33c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/022ba856a87c8f40739b7ef2fdcdf33c?s=96&d=mm&r=g","caption":"Caitlin Neiman"},"description":"Add-ons Community Manager at Mozilla.","url":"https:\/\/blog.mozilla.org\/addons\/author\/cneimanmozilla-com\/"}]}},"_links":{"self":[{"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/posts\/8418"}],"collection":[{"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/users\/1405"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/comments?post=8418"}],"version-history":[{"count":0,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/posts\/8418\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/media\/8419"}],"wp:attachment":[{"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/media?parent=8418"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/categories?post=8418"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.mozilla.org\/addons\/wp-json\/wp\/v2\/tags?post=8418"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}