@zthun/janitor-web 16.1.1 → 17.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/LICENSE.md +14 -10
  2. package/dist/assets/main.js +1 -1
  3. package/dist/classes/_zthun_lint_janitor.ZConfigExtender.html +5 -5
  4. package/dist/classes/_zthun_lint_janitor.ZConfigReaderCosmic.html +7 -7
  5. package/dist/classes/_zthun_lint_janitor.ZConfigReaderNull.html +2 -2
  6. package/dist/classes/_zthun_lint_janitor.ZConfigReaderPrettier.html +2 -2
  7. package/dist/classes/_zthun_lint_janitor.ZContentLinterHtml.html +2 -2
  8. package/dist/classes/_zthun_lint_janitor.ZContentLinterJson.html +2 -2
  9. package/dist/classes/_zthun_lint_janitor.ZContentLinterPretty.html +2 -2
  10. package/dist/classes/_zthun_lint_janitor.ZContentLinterYaml.html +2 -2
  11. package/dist/classes/_zthun_lint_janitor.ZFileReportLint.html +3 -3
  12. package/dist/classes/_zthun_lint_janitor.ZLintJanitor.html +13 -13
  13. package/dist/classes/_zthun_lint_janitor.ZLinterEs.html +4 -4
  14. package/dist/classes/_zthun_lint_janitor.ZLinterFile.html +3 -3
  15. package/dist/classes/_zthun_lint_janitor.ZLinterMarkdown.html +3 -3
  16. package/dist/classes/_zthun_lint_janitor.ZLinterSilent.html +3 -3
  17. package/dist/classes/_zthun_lint_janitor.ZLinterSpelling.html +3 -3
  18. package/dist/classes/_zthun_lint_janitor.ZLinterStyle.html +3 -3
  19. package/dist/index.html +14 -10
  20. package/dist/interfaces/_zthun_lint_janitor.IZConfigDiscovery.html +2 -2
  21. package/dist/interfaces/_zthun_lint_janitor.IZConfigExtender.html +2 -2
  22. package/dist/interfaces/_zthun_lint_janitor.IZConfigReader.html +2 -2
  23. package/dist/interfaces/_zthun_lint_janitor.IZContentLinter.html +2 -2
  24. package/dist/interfaces/_zthun_lint_janitor.IZLintJanitorArgs.html +2 -2
  25. package/dist/interfaces/_zthun_lint_janitor.IZLintJanitorOptions.html +2 -2
  26. package/dist/interfaces/_zthun_lint_janitor.IZLinter.html +2 -2
  27. package/dist/media/CODE_OF_CONDUCT.md +70 -44
  28. package/dist/media/CONTRIBUTING.md +33 -23
  29. package/dist/media/LICENSE.md +14 -10
  30. package/dist/modules/_zthun_eslint_config.html +4 -2
  31. package/dist/modules/_zthun_htmlhint_config.html +5 -3
  32. package/dist/modules/_zthun_lint_janitor.html +177 -121
  33. package/dist/modules/_zthun_lint_janitor_config.html +2 -1
  34. package/dist/modules/_zthun_markdownlint_config.html +4 -3
  35. package/dist/modules/_zthun_prettier_config.html +1 -1
  36. package/dist/modules/_zthun_stylelint_config_less.html +2 -1
  37. package/dist/modules/_zthun_stylelint_config_sass.html +2 -1
  38. package/package.json +6 -6
@@ -1,29 +1,41 @@
1
1
  <!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>@zthun/lint-janitor | Janitor</title><meta name="description" content="Documentation for Janitor"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><link rel="icon" href="../janitor.svg" />
2
- </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_lint_janitor.html">@zthun/lint-janitor</a></li></ul><h1>Module @zthun/lint-janitor</h1></div><section class="tsd-panel tsd-typography"><a id="md:lint-janitor" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Lint Janitor<a href="#md:lint-janitor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>Code gets messy. You will find that most places you work at will always have a big long list of tech debt tasks that
3
- need to be taken care of and this becomes a maintenance nightmare as it becomes very expensive to fix. Companies rarely
4
- want to let developers fix these issues because they tend to only look at the short term ROI, which isn't high for this
5
- kind of task. What then happens is that more functional, but messy, code gets introduced and the software begins to rot.</p>
6
- <p>One way to fix something like this is to start with linters. Linters will scour through your code base and notify you
7
- that you have various issues. In a good development pipeline, they will prevent developers from generating a messy room
8
- and will force them to write clean consistent code with the rest of the development team. They aren't a silver bullet,
9
- and messy solutions can still crop up, but linters take care of most of the inconsistent and formatting errors that can
10
- develop in a code base. Good developers love them - it keeps the entire team consistent in their code structure.</p>
11
- <p>Of course, linters are not without their issues as well. There's an outrageous amount of them out there and you have to
12
- be well versed in each one of them in order to set each one of them up and run them in your pipeline to verify all of
13
- the different code files you have. There's linters for code, applications, spelling, and formatting; it's easy to get
14
- overwhelmed.</p>
15
- <p><strong>Lint Janitor</strong> was created under the guise that there is beauty in simplicity. Having a single application that takes
16
- care of ones needs leads to greater happiness then having to piece meal together tons of tools, each with individual
17
- needs and maintainability issues. Just let <strong>Lint Janitor</strong> do the heavy lifting for you.</p>
2
+ </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_lint_janitor.html">@zthun/lint-janitor</a></li></ul><h1>Module @zthun/lint-janitor</h1></div><section class="tsd-panel tsd-typography"><a id="md:lint-janitor" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Lint Janitor<a href="#md:lint-janitor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>Code gets messy. You will find that most places you work at will always have a
3
+ big long list of tech debt tasks that need to be taken care of and this becomes
4
+ a maintenance nightmare as it becomes very expensive to fix. Companies rarely
5
+ want to let developers fix these issues because they tend to only look at the
6
+ short term ROI, which isn't high for this kind of task. What then happens is
7
+ that more functional, but messy, code gets introduced and the software begins to
8
+ rot.</p>
9
+ <p>One way to fix something like this is to start with linters. Linters will scour
10
+ through your code base and notify you that you have various issues. In a good
11
+ development pipeline, they will prevent developers from generating a messy room
12
+ and will force them to write clean consistent code with the rest of the
13
+ development team. They aren't a silver bullet, and messy solutions can still
14
+ crop up, but linters take care of most of the inconsistent and formatting errors
15
+ that can develop in a code base. Good developers love them - it keeps the entire
16
+ team consistent in their code structure.</p>
17
+ <p>Of course, linters are not without their issues as well. There's an outrageous
18
+ amount of them out there and you have to be well versed in each one of them in
19
+ order to set each one of them up and run them in your pipeline to verify all of
20
+ the different code files you have. There's linters for code, applications,
21
+ spelling, and formatting; it's easy to get overwhelmed.</p>
22
+ <p><strong>Lint Janitor</strong> was created under the guise that there is beauty in simplicity.
23
+ Having a single application that takes care of ones needs leads to greater
24
+ happiness then having to piece meal together tons of tools, each with individual
25
+ needs and maintainability issues. Just let <strong>Lint Janitor</strong> do the heavy lifting
26
+ for you.</p>
18
27
  <a id="md:getting-started" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Getting Started<a href="#md:getting-started" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><pre><code class="sh"><span class="hl-0"># NPM</span><br/><span class="hl-1">npm</span><span class="hl-2"> </span><span class="hl-3">install</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor</span><span class="hl-2"> </span><span class="hl-4">--save-dev</span><br/><span class="hl-0"># Yarn</span><br/><span class="hl-1">yarn</span><span class="hl-2"> </span><span class="hl-3">add</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor</span><span class="hl-2"> </span><span class="hl-4">--dev</span>
19
28
  </code><button type="button">Copy</button></pre>
20
29
 
21
- <a id="md:configuration" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Configuration<a href="#md:configuration" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><p>Lint Janitor uses an opt-in approach to linting, meaning that it will not lint any files that you do not tell it to
22
- lint. You will need to add a configuration file that describes the list of files to lint and the sub configurations of
23
- each internal linter. Each linter is described in further detail. In the end, the expectation is that you will provide
24
- you're own collection of shared configurations that you can reuse in all your projects.</p>
25
- <p>Lint Janitor uses the <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a> standard for loading its configuration.
26
- In short, it will search the current working directory for the following files:</p>
30
+ <a id="md:configuration" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Configuration<a href="#md:configuration" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><p>Lint Janitor uses an opt-in approach to linting, meaning that it will not lint
31
+ any files that you do not tell it to lint. You will need to add a configuration
32
+ file that describes the list of files to lint and the sub configurations of each
33
+ internal linter. Each linter is described in further detail. In the end, the
34
+ expectation is that you will provide you're own collection of shared
35
+ configurations that you can reuse in all your projects.</p>
36
+ <p>Lint Janitor uses the <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a>
37
+ standard for loading its configuration. In short, it will search the current
38
+ working directory for the following files:</p>
27
39
  <ol>
28
40
  <li>A property in your package.json named <strong>lint-janitor</strong>.</li>
29
41
  <li>A json file or yaml file named <strong>lint-janitorrc</strong>.</li>
@@ -32,8 +44,9 @@ In short, it will search the current working directory for the following files:<
32
44
  <li>A javascript file named <strong>lint-janitorrc.js</strong>, <strong>lint-janitor.config.js</strong>.</li>
33
45
  </ol>
34
46
  <blockquote>
35
- <p>It is highly recommended to use a config.js convention for these types of configurations. The main reason is that
36
- config.js offers the most flexible way to configure an application and also naturally allows you to use the module
47
+ <p>It is highly recommended to use a config.js convention for these types of
48
+ configurations. The main reason is that config.js offers the most flexible way
49
+ to configure an application and also naturally allows you to use the module
37
50
  syntax to import other configurations.</p>
38
51
  </blockquote>
39
52
  <p>The configuration file uses the following schema.</p>
@@ -52,31 +65,41 @@ syntax to import other configurations.</p>
52
65
  <pre><code class="sh"><span class="hl-0"># NPM</span><br/><span class="hl-1">npm</span><span class="hl-2"> </span><span class="hl-3">run</span><span class="hl-2"> </span><span class="hl-3">lint</span><br/><span class="hl-0"># Yarn</span><br/><span class="hl-1">yarn</span><span class="hl-2"> </span><span class="hl-3">lint</span><br/><span class="hl-0"># NPX</span><br/><span class="hl-1">npx</span><span class="hl-2"> </span><span class="hl-3">lint-janitor</span>
53
66
  </code><button type="button">Copy</button></pre>
54
67
 
55
- <a id="md:command-line" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Command Line<a href="#md:command-line" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><p>You can always run lint-janitor on the command line using npx or if it is installed globally, which is not recommended.
56
- There are very few command line options, as lint-janitor intends to be fully driven by the config file.</p>
68
+ <a id="md:command-line" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Command Line<a href="#md:command-line" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><p>You can always run lint-janitor on the command line using npx or if it is
69
+ installed globally, which is not recommended. There are very few command line
70
+ options, as lint-janitor intends to be fully driven by the config file.</p>
57
71
  <p><strong>lint-janitor</strong> [options]</p>
58
72
  <pre><code class="json"><span class="hl-2">[</span><br/><span class="hl-2"> { </span><span class="hl-5">&quot;option&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;--version&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;description&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;Show version number&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;type&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;boolean&quot;</span><span class="hl-2"> }</span><br/><span class="hl-2"> { </span><span class="hl-5">&quot;option&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;--config&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;alias&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;-c&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;description&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;Optional config file to use&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;type&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;string&quot;</span><span class="hl-2"> },</span><br/><span class="hl-2"> { </span><span class="hl-5">&quot;option&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;--help&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;description&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;Show help&quot;</span><span class="hl-2">, </span><span class="hl-5">&quot;type&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;boolean&quot;</span><span class="hl-2"> }</span><br/><span class="hl-2">]</span>
59
73
  </code><button type="button">Copy</button></pre>
60
74
 
61
- <a id="md:linters" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Linters<a href="#md:linters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><a id="md:shared-configurations" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Shared Configurations<a href="#md:shared-configurations" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>While you can always recreate individual configurations for each linter, it is <strong>HIGHLY</strong> recommended to create a set of
62
- shared configurations for your organization. Most linters supported by Lint Janitor have some form of support for
63
- extending configurations and sharing them so you don't need to reinvent the wheel. In the place that such extensions are
64
- missing, Lint Janitor attempts to bridge this gap but it will not add support for IDE based tooling and extensions.
65
- You'll have to decide what's best for your project and your organization.</p>
66
- <p>One note is that the housing repository for lint-janitor contains multiple shared configurations used by zthun scoped
67
- projects. You can use them, but it is recommended for your organization to create it's own set of configurations that
75
+ <a id="md:linters" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Linters<a href="#md:linters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><a id="md:shared-configurations" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Shared Configurations<a href="#md:shared-configurations" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>While you can always recreate individual configurations for each linter, it is
76
+ <strong>HIGHLY</strong> recommended to create a set of shared configurations for your
77
+ organization. Most linters supported by Lint Janitor have some form of support
78
+ for extending configurations and sharing them so you don't need to reinvent the
79
+ wheel. In the place that such extensions are missing, Lint Janitor attempts to
80
+ bridge this gap but it will not add support for IDE based tooling and
81
+ extensions. You'll have to decide what's best for your project and your
82
+ organization.</p>
83
+ <p>One note is that the housing repository for lint-janitor contains multiple
84
+ shared configurations used by zthun scoped projects. You can use them, but it is
85
+ recommended for your organization to create it's own set of configurations that
68
86
  meets its needs.</p>
69
- <a id="md:json-and-yaml" class="tsd-anchor"></a><h3 class="tsd-anchor-link">JSON and YAML<a href="#md:json-and-yaml" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>JSON does not use an external tool. It's impossible to have lint errors in JSON as if there are, it wouldn't be valid
70
- JSON and you won't be able to parse it. Thus, when we talk about linting JSON, it's really just a parse check to make
87
+ <a id="md:json-and-yaml" class="tsd-anchor"></a><h3 class="tsd-anchor-link">JSON and YAML<a href="#md:json-and-yaml" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>JSON does not use an external tool. It's impossible to have lint errors in JSON
88
+ as if there are, it wouldn't be valid JSON and you won't be able to parse it.
89
+ Thus, when we talk about linting JSON, it's really just a parse check to make
71
90
  sure you're JSON is valid.</p>
72
- <p>For YAML, the same rule applies. It's just a parse check, but since YAML isn't supported in JavaScript out of the box,
73
- it uses <a href="https://www.npmjs.com/package/js-yaml">js-yaml</a> under the hood to parse and check your files.</p>
91
+ <p>For YAML, the same rule applies. It's just a parse check, but since YAML isn't
92
+ supported in JavaScript out of the box, it uses
93
+ <a href="https://www.npmjs.com/package/js-yaml">js-yaml</a> under the hood to parse and
94
+ check your files.</p>
74
95
  <p>Neither of these checks verify schemas so be warned about that.</p>
75
- <a id="md:ecmascript" class="tsd-anchor"></a><h3 class="tsd-anchor-link">ECMAScript<a href="#md:ecmascript" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>The linter of choice for ECMAScript, is <a href="https://eslint.org/">ESLint</a>. ESLint has a very large eco system with support
76
- for shared configurations and plugins. It supports both TypeScript and JavaScript so it covers the entire feature
96
+ <a id="md:ecmascript" class="tsd-anchor"></a><h3 class="tsd-anchor-link">ECMAScript<a href="#md:ecmascript" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>The linter of choice for ECMAScript, is <a href="https://eslint.org/">ESLint</a>. ESLint
97
+ has a very large eco system with support for shared configurations and plugins.
98
+ It supports both TypeScript and JavaScript so it covers the entire feature
77
99
  spectrum. The configuration file for ESLint uses something similar to a
78
- <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a> standard but it's more restrictive. Instead, it looks for the
79
- following files in the current working directory.</p>
100
+ <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a> standard but it's more
101
+ restrictive. Instead, it looks for the following files in the current working
102
+ directory.</p>
80
103
  <ol>
81
104
  <li>.eslintrc.js</li>
82
105
  <li>.eslintrc.cjs</li>
@@ -85,13 +108,15 @@ following files in the current working directory.</p>
85
108
  <li>.eslintrc.json</li>
86
109
  <li>package.json</li>
87
110
  </ol>
88
- <p>There is also a <a href="https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint">VisualStudio Code plugin</a>
89
- that will give you highlighting for any linting errors while you type. This makes ESLint the go to linter for web based
90
- ECMAScript code.</p>
91
- <p>For the configuration schema, you can find it <a href="https://eslint.org/docs/user-guide/configuring/">here</a>. If you create a
92
- shared configuration, as recommended, you can simply add that to the extends key in the ESLint configuration file to
93
- share configuration throughout your organization.</p>
94
- <pre><code class="js"><span class="hl-0">// .eslintrc.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&#39;@zthun/eslint-config&#39;</span><span class="hl-2">);</span>
111
+ <p>There is also a
112
+ <a href="https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint">VisualStudio Code plugin</a>
113
+ that will give you highlighting for any linting errors while you type. This
114
+ makes ESLint the go to linter for web based ECMAScript code.</p>
115
+ <p>For the configuration schema, you can find it
116
+ <a href="https://eslint.org/docs/user-guide/configuring/">here</a>. If you create a shared
117
+ configuration, as recommended, you can simply add that to the extends key in the
118
+ ESLint configuration file to share configuration throughout your organization.</p>
119
+ <pre><code class="js"><span class="hl-0">// .eslintrc.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&quot;@zthun/eslint-config&quot;</span><span class="hl-2">);</span>
95
120
  </code><button type="button">Copy</button></pre>
96
121
 
97
122
  <a id="md:styles-css-less-sass" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Styles (CSS, Less, SASS)<a href="#md:styles-css-less-sass" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>There are several linters for style based files.</p>
@@ -100,112 +125,143 @@ share configuration throughout your organization.</p>
100
125
  <li><a href="https://github.com/sasstools/sass-lint">SassLint</a></li>
101
126
  <li><a href="https://stylelint.io/">StyleLint</a></li>
102
127
  </ol>
103
- <p>CSSLint and SassLint are no longer actively maintained. Thus, for linting style based files, Lint Janitor uses StyleLint
104
- under the hood.</p>
105
- <p>StyleLint is similar to <a href="https://eslint.org/">ESLint</a>. It too, has a nice ecosystem of plugins and it supports shared
106
- configurations. Stylelint, unlike ESLint, does support the <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a>
107
- standard, but it is recommended to use .stylelintrc.json convention. The main reason is that the actual
108
- <a href="https://marketplace.visualstudio.com/items?itemName=stylelint.vscode-stylelint">VisualStudio Code plugin</a> specifically
109
- looks for this file so you can get lint errors directly in your IDE.</p>
110
- <p>You can find the configuration schema <a href="https://stylelint.io/user-guide/configure">here</a> and you can use the extends key
111
- in the configuration to load a shared configuration.</p>
112
- <pre><code class="jsonc"><span class="hl-0">// .stylelintrc.json</span><br/><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;extends&quot;</span><span class="hl-2">: [</span><span class="hl-3">&quot;@zthun/stylelint-config&quot;</span><span class="hl-2">]</span><br/><span class="hl-2">}</span>
128
+ <p>CSSLint and SassLint are no longer actively maintained. Thus, for linting style
129
+ based files, Lint Janitor uses StyleLint under the hood.</p>
130
+ <p>StyleLint is similar to <a href="https://eslint.org/">ESLint</a>. It too, has a nice
131
+ ecosystem of plugins and it supports shared configurations. Stylelint, unlike
132
+ ESLint, does support the
133
+ <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a> standard, but it is
134
+ recommended to use .stylelintrc.json convention. The main reason is that the
135
+ actual
136
+ <a href="https://marketplace.visualstudio.com/items?itemName=stylelint.vscode-stylelint">VisualStudio Code plugin</a>
137
+ specifically looks for this file so you can get lint errors directly in your
138
+ IDE.</p>
139
+ <p>You can find the configuration schema
140
+ <a href="https://stylelint.io/user-guide/configure">here</a> and you can use the extends
141
+ key in the configuration to load a shared configuration.</p>
142
+ <pre><code class="jsonc"><span class="hl-0">// .stylelintrc.json</span><br/><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;extends&quot;</span><span class="hl-2">: [</span><span class="hl-3">&quot;@zthun/stylelint-config&quot;</span><span class="hl-2">],</span><br/><span class="hl-2">}</span>
113
143
  </code><button type="button">Copy</button></pre>
114
144
 
115
- <p>As usual, the list of html rules are <a href="https://htmlhint.com/docs/user-guide/list-rules">here</a>.</p>
116
- <a id="md:html" class="tsd-anchor"></a><h3 class="tsd-anchor-link">HTML<a href="#md:html" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>There is not a lot of support for HTML linters. There is only really one that is used and it is somewhat old and doesn't
117
- have a lot of support. A promise of a 1.0.0 release has been made, but we will have to wait and see what happens. That
145
+ <p>As usual, the list of html rules are
146
+ <a href="https://htmlhint.com/docs/user-guide/list-rules">here</a>.</p>
147
+ <a id="md:html" class="tsd-anchor"></a><h3 class="tsd-anchor-link">HTML<a href="#md:html" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>There is not a lot of support for HTML linters. There is only really one that is
148
+ used and it is somewhat old and doesn't have a lot of support. A promise of a
149
+ 1.0.0 release has been made, but we will have to wait and see what happens. That
118
150
  application is <a href="https://github.com/htmlhint/HTMLHint">HTMLHint</a>.</p>
119
151
  <p>HTMLHint does NOT support shared configurations at all. To do that,
120
- <a href="https://github.com/htmlhint/HTMLHint/issues/621">this issue</a> would need to be approved and supported. In the meantime,
121
- Lint Janitor bridges this gap by sending just the content to HTMLHint instead of the file list. This allows Lint Janitor
122
- to implement a <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a> standard for loading and extending the
123
- configuration to support shared configs. It will be up to you if you want to do this because the
124
- <a href="https://marketplace.visualstudio.com/items?itemName=mkaufman.HTMLHint">VisualStudio Code plugin</a> does not support this
125
- and expects the standard json file to be at the root of your project.</p>
126
- <p>If you do choose to use a shared configuration, you can just use a htmlhint.config.js file at the root of your
127
- repository.</p>
128
- <pre><code class="js"><span class="hl-0">//htmlhint.config.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&#39;@zthun/htmlhint-config&#39;</span><span class="hl-2">);</span>
152
+ <a href="https://github.com/htmlhint/HTMLHint/issues/621">this issue</a> would need to be
153
+ approved and supported. In the meantime, Lint Janitor bridges this gap by
154
+ sending just the content to HTMLHint instead of the file list. This allows Lint
155
+ Janitor to implement a <a href="https://www.npmjs.com/package/cosmiconfig">cosmiconfig</a>
156
+ standard for loading and extending the configuration to support shared configs.
157
+ It will be up to you if you want to do this because the
158
+ <a href="https://marketplace.visualstudio.com/items?itemName=mkaufman.HTMLHint">VisualStudio Code plugin</a>
159
+ does not support this and expects the standard json file to be at the root of
160
+ your project.</p>
161
+ <p>If you do choose to use a shared configuration, you can just use a
162
+ htmlhint.config.js file at the root of your repository.</p>
163
+ <pre><code class="js"><span class="hl-0">//htmlhint.config.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&quot;@zthun/htmlhint-config&quot;</span><span class="hl-2">);</span>
129
164
  </code><button type="button">Copy</button></pre>
130
165
 
131
166
  <a id="md:markdown" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Markdown<a href="#md:markdown" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Good old markdown has a couple of linters available, but considering that
132
167
  <a href="https://github.com/DavidAnson/markdownlint">MarkdownLint</a> has a working
133
- <a href="https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint">VisualStudio Code plugin</a>, that's
134
- the one that Lint Janitor uses.</p>
135
- <p>MarkdownLint searches for the following configuration files at the root of your repository.</p>
168
+ <a href="https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint">VisualStudio Code plugin</a>,
169
+ that's the one that Lint Janitor uses.</p>
170
+ <p>MarkdownLint searches for the following configuration files at the root of your
171
+ repository.</p>
136
172
  <ol>
137
173
  <li>.markdownlint.json</li>
138
174
  <li>.markdownlint.yaml or .markdownlint.yml</li>
139
175
  <li>.markdownlintrc</li>
140
176
  </ol>
141
- <p>Strangely enough, if you are using the vscode plugin, then it is recommended to just use the .markdownlint.json name
142
- because that seems to be the only one that the plugin will respect. There's not a lot of rules to markdown. You can find
143
- the list of rules <a href="https://github.com/DavidAnson/markdownlint">here</a>. While it's not documented, MarkdownLint does have
144
- support for shared configurations, but there is a gotcha with it. The actual shared configuration MUST be in a json
145
- format. If you are creating a shared configuration for markdown, you will want to export a module of it and also have an
146
- actual json formatted file that comes along with it.</p>
177
+ <p>Strangely enough, if you are using the vscode plugin, then it is recommended to
178
+ just use the .markdownlint.json name because that seems to be the only one that
179
+ the plugin will respect. There's not a lot of rules to markdown. You can find
180
+ the list of rules <a href="https://github.com/DavidAnson/markdownlint">here</a>. While it's
181
+ not documented, MarkdownLint does have support for shared configurations, but
182
+ there is a gotcha with it. The actual shared configuration MUST be in a json
183
+ format. If you are creating a shared configuration for markdown, you will want
184
+ to export a module of it and also have an actual json formatted file that comes
185
+ along with it.</p>
147
186
  <pre><code class="json"><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;extends&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;@zthun/markdownlint-config/as-json&quot;</span><br/><span class="hl-2">}</span><br/><br/><span class="hl-0">// node_modules/@zthun/markdownlint-config/as-json.json</span><br/><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;line-length&quot;</span><span class="hl-2">: </span><span class="hl-4">false</span><span class="hl-2">,</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;no-inline-html&quot;</span><span class="hl-2">: </span><span class="hl-4">false</span><span class="hl-2">,</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;no-duplicate-heading&quot;</span><span class="hl-2">: </span><span class="hl-4">false</span><br/><span class="hl-2">}</span>
148
187
  </code><button type="button">Copy</button></pre>
149
188
 
150
189
  <p>You can still export a node module that has your shared configuration.</p>
151
- <pre><code class="js"><span class="hl-0">// index.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&#39;./as-json.json&#39;</span><span class="hl-2">);</span>
190
+ <pre><code class="js"><span class="hl-0">// index.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&quot;./as-json.json&quot;</span><span class="hl-2">);</span>
152
191
  </code><button type="button">Copy</button></pre>
153
192
 
154
- <a id="md:spelling" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Spelling<a href="#md:spelling" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>This one is pretty optional, but it's useful in that it keeps you honest. With spelling, you won't use a shared
155
- configuration as this is truly unique across all projects. It is not possible to have a be all end all language that
156
- knows every word in existence so this will look for the <a href="https://www.npmjs.com/package/cspell">CSpell</a> configuration at
157
- the root of the repository. If you combine this with the
193
+ <a id="md:spelling" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Spelling<a href="#md:spelling" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>This one is pretty optional, but it's useful in that it keeps you honest. With
194
+ spelling, you won't use a shared configuration as this is truly unique across
195
+ all projects. It is not possible to have a be all end all language that knows
196
+ every word in existence so this will look for the
197
+ <a href="https://www.npmjs.com/package/cspell">CSpell</a> configuration at the root of the
198
+ repository. If you combine this with the
158
199
  <a href="https://marketplace.visualstudio.com/items?itemName=streetsidesoftware.code-spell-checker">VisualStudio Code plugin</a>,
159
- it's pretty powerful and lets you add words as the repository vocabulary grows. When using spelling here, you'll need to
160
- decide if there are words you want to support, what dictionaries your repository is going to support, and what are your
161
- forbidden words and phrases. There are no rules here, just lists of allowed words and dictionaries.</p>
162
- <p>You may want to consider having a shared dictionary for your organizations custom lingo. You can do this through the
163
- dictionaryDefinitions key, but you'll have to export a txt file for reuse.</p>
200
+ it's pretty powerful and lets you add words as the repository vocabulary grows.
201
+ When using spelling here, you'll need to decide if there are words you want to
202
+ support, what dictionaries your repository is going to support, and what are
203
+ your forbidden words and phrases. There are no rules here, just lists of allowed
204
+ words and dictionaries.</p>
205
+ <p>You may want to consider having a shared dictionary for your organizations
206
+ custom lingo. You can do this through the dictionaryDefinitions key, but you'll
207
+ have to export a txt file for reuse.</p>
164
208
  <pre><code class="json"><span class="hl-0">// cspell.json</span><br/><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;version&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;0.1&quot;</span><span class="hl-2">,</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;$schema&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;https://raw.githubusercontent.com/streetsidesoftware/cspell/master/cspell.schema.json&quot;</span><span class="hl-2">,</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;language&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;en&quot;</span><span class="hl-2">,</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;words&quot;</span><span class="hl-2">: [</span><span class="hl-3">&quot;errored&quot;</span><span class="hl-2">],</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;dictionaries&quot;</span><span class="hl-2">: [</span><span class="hl-3">&quot;typescript&quot;</span><span class="hl-2">, </span><span class="hl-3">&quot;en_US&quot;</span><span class="hl-2">]</span><br/><span class="hl-2">}</span>
165
209
  </code><button type="button">Copy</button></pre>
166
210
 
167
- <a id="md:formatting" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Formatting<a href="#md:formatting" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Finally, and possibly most importantly, is code formatting consistency. There are generally two tools that are used for
168
- this.</p>
211
+ <a id="md:formatting" class="tsd-anchor"></a><h3 class="tsd-anchor-link">Formatting<a href="#md:formatting" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Finally, and possibly most importantly, is code formatting consistency. There
212
+ are generally two tools that are used for this.</p>
169
213
  <ol>
170
214
  <li><a href="https://editorconfig.org/">EditorConfig</a></li>
171
215
  <li><a href="https://prettier.io/">Prettier</a></li>
172
216
  </ol>
173
- <p>For code formatting, Lint Janitor went with Prettier since it supports all the features of EditorConfig and a bunch of
174
- others. Prettier also supports shared configurations and is highly recommended to use them because the
175
- <a href="https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode">VisualStudio Code plugin</a> has support to
176
- auto format your files when you save them, making sure that your teams formatting is completely consistent.</p>
177
- <p>It's file lookup is similar to that of ESLint, but we recommended using .prettierrc.js to enable support for shared
178
- configurations.</p>
179
- <pre><code class="js"><span class="hl-0">//.prettierrc.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&#39;@zthun/prettier-config&#39;</span><span class="hl-2">);</span>
217
+ <p>For code formatting, Lint Janitor went with Prettier since it supports all the
218
+ features of EditorConfig and a bunch of others. Prettier also supports shared
219
+ configurations and is highly recommended to use them because the
220
+ <a href="https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode">VisualStudio Code plugin</a>
221
+ has support to auto format your files when you save them, making sure that your
222
+ teams formatting is completely consistent.</p>
223
+ <p>It's file lookup is similar to that of ESLint, but we recommended using
224
+ .prettierrc.js to enable support for shared configurations.</p>
225
+ <pre><code class="js"><span class="hl-0">//.prettierrc.js</span><br/><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&quot;@zthun/prettier-config&quot;</span><span class="hl-2">);</span>
180
226
  </code><button type="button">Copy</button></pre>
181
227
 
182
- <p>Options are <a href="https://prettier.io/docs/en/options.html">here</a>, and there's not a lot of them. See
183
- <a href="https://prettier.io/docs/en/option-philosophy.html">why</a>, as there's a good reason for this.</p>
184
- <p>When doing formatting linting, only the formatting is checked and you are notified if the files are formatted or
185
- unformatted. The best way to prevent these issues all together is to just use the Prettier IDE extension and auto format
186
- as you type.</p>
228
+ <p>Options are <a href="https://prettier.io/docs/en/options.html">here</a>, and there's not a
229
+ lot of them. See <a href="https://prettier.io/docs/en/option-philosophy.html">why</a>, as
230
+ there's a good reason for this.</p>
231
+ <p>When doing formatting linting, only the formatting is checked and you are
232
+ notified if the files are formatted or unformatted. The best way to prevent
233
+ these issues all together is to just use the Prettier IDE extension and auto
234
+ format as you type.</p>
187
235
  <a id="md:faq" class="tsd-anchor"></a><h3 class="tsd-anchor-link">FAQ<a href="#md:faq" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><p>Q. Can this support my other favorite linter?</p>
188
- <p>A. Possibly, but whether or not Lint Janitor will bother at the moment depends on a few factors:</p>
236
+ <p>A. Possibly, but whether or not Lint Janitor will bother at the moment depends
237
+ on a few factors:</p>
189
238
  <ol>
190
- <li>Is there an IDE plugin that makes it so you can validate, lint, and cleanup while you go along so you're not left
191
- with a lot of surprises at the end?</li>
192
- <li>Does the linter support shared configuration to not reinvent the wheel everywhere? Does Lint Janitor have to bridge
193
- that gap?</li>
194
- <li>Is the linter in question a node linter that has its API exported and can be integrated into a node application?
195
- <strong>Important!</strong></li>
239
+ <li>Is there an IDE plugin that makes it so you can validate, lint, and cleanup
240
+ while you go along so you're not left with a lot of surprises at the end?</li>
241
+ <li>Does the linter support shared configuration to not reinvent the wheel
242
+ everywhere? Does Lint Janitor have to bridge that gap?</li>
243
+ <li>Is the linter in question a node linter that has its API exported and can be
244
+ integrated into a node application? <strong>Important!</strong></li>
196
245
  </ol>
197
- <p>If you answered No to the last question, then the answer is No. Lint Janitor does not invoke external command lines of
198
- linters and instead calls into their node API directly. This is how Lint Janitor succeeds in not having you worry about
199
- what tools to install and what versions to use; it uses transitive dependencies.</p>
200
- <p>If the last question is a Yes, then it becomes a question of, is it worth it? That'll need to be prioritized. For the
201
- most part, using <a href="https://prettier.io/">Prettier</a> takes care of almost all linting issues so you may not need more than
202
- what is available here. If you need the mother of all linters, there is the heavy
203
- <a href="https://github.com/nvuillam/mega-linter">Mega Linter</a> which aggregates every linter in existence. Very cool, but a bit
204
- overkill for the solution we are trying to solve with Lint Janitor.</p>
246
+ <p>If you answered No to the last question, then the answer is No. Lint Janitor
247
+ does not invoke external command lines of linters and instead calls into their
248
+ node API directly. This is how Lint Janitor succeeds in not having you worry
249
+ about what tools to install and what versions to use; it uses transitive
250
+ dependencies.</p>
251
+ <p>If the last question is a Yes, then it becomes a question of, is it worth it?
252
+ That'll need to be prioritized. For the most part, using
253
+ <a href="https://prettier.io/">Prettier</a> takes care of almost all linting issues so you
254
+ may not need more than what is available here. If you need the mother of all
255
+ linters, there is the heavy
256
+ <a href="https://github.com/nvuillam/mega-linter">Mega Linter</a> which aggregates every
257
+ linter in existence. Very cool, but a bit overkill for the solution we are
258
+ trying to solve with Lint Janitor.</p>
205
259
  <p>Q. Is there an IDE plugin for Lint Janitor?</p>
206
- <p>A. Not yet. That would solve the issue of wanting an IDE plugin for each individual linter and would allow you to just
207
- have a single lint-janitor.config.js file at the root of your repository that would handle all linting needs. There is
208
- one planned, but it still need to be researched and scoped out.</p>
260
+ <p>A. Not yet. That would solve the issue of wanting an IDE plugin for each
261
+ individual linter and would allow you to just have a single
262
+ lint-janitor.config.js file at the root of your repository that would handle all
263
+ linting needs. There is one planned, but it still need to be researched and
264
+ scoped out.</p>
209
265
  </section><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><h3 class="tsd-index-heading uppercase">Index</h3><section class="tsd-index-section"><h3 class="tsd-index-heading">Classes</h3><div class="tsd-index-list"><a href="../classes/_zthun_lint_janitor.ZConfigExtender.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-128"></use></svg><span>ZConfig<wbr/>Extender</span></a>
210
266
  <a href="../classes/_zthun_lint_janitor.ZConfigReaderCosmic.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-128"></use></svg><span>ZConfig<wbr/>Reader<wbr/>Cosmic</span></a>
211
267
  <a href="../classes/_zthun_lint_janitor.ZConfigReaderNull.html" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-128"></use></svg><span>ZConfig<wbr/>Reader<wbr/>Null</span></a>
@@ -1,5 +1,6 @@
1
1
  <!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>@zthun/lint-janitor-config | Janitor</title><meta name="description" content="Documentation for Janitor"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><link rel="icon" href="../janitor.svg" />
2
- </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_lint_janitor_config.html">@zthun/lint-janitor-config</a></li></ul><h1>Module @zthun/lint-janitor-config</h1></div><section class="tsd-panel tsd-typography"><a id="md:lint-janitor-config" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Lint Janitor Config<a href="#md:lint-janitor-config" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>This is a shared configuration for lint-janitor that contains all of the zthun scoped shared configurations.</p>
2
+ </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_lint_janitor_config.html">@zthun/lint-janitor-config</a></li></ul><h1>Module @zthun/lint-janitor-config</h1></div><section class="tsd-panel tsd-typography"><a id="md:lint-janitor-config" class="tsd-anchor"></a><h1 class="tsd-anchor-link">Lint Janitor Config<a href="#md:lint-janitor-config" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>This is a shared configuration for lint-janitor that contains all of the zthun
3
+ scoped shared configurations.</p>
3
4
  <a id="md:getting-started" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Getting Started<a href="#md:getting-started" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><pre><code class="sh"><span class="hl-0"># NPM</span><br/><span class="hl-1">npm</span><span class="hl-2"> </span><span class="hl-3">install</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor-config</span><span class="hl-2"> </span><span class="hl-4">--save-dev</span><br/><span class="hl-0"># Yarn</span><br/><span class="hl-1">yarn</span><span class="hl-2"> </span><span class="hl-3">add</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor</span><span class="hl-2"> </span><span class="hl-3">@zthun/lint-janitor-config</span><span class="hl-2"> </span><span class="hl-4">--dev</span>
4
5
  </code><button type="button">Copy</button></pre>
5
6
 
@@ -7,9 +7,10 @@
7
7
  <pre><code class="json"><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;extends&quot;</span><span class="hl-2">: [</span><span class="hl-3">&quot;@zthun/markdownlint-config&quot;</span><span class="hl-2">]</span><br/><span class="hl-2">}</span>
8
8
  </code><button type="button">Copy</button></pre>
9
9
 
10
- <p>That's it. You now have the recommended rules for zthun scoped projects when using lint-janitor.</p>
11
- <p>If you are using the Atom or VSCode plugin, it may not recognize the imported js configuration style. Instead, you can
12
- use the provided as-json.json file.</p>
10
+ <p>That's it. You now have the recommended rules for zthun scoped projects when
11
+ using lint-janitor.</p>
12
+ <p>If you are using the Atom or VSCode plugin, it may not recognize the imported js
13
+ configuration style. Instead, you can use the provided as-json.json file.</p>
13
14
  <pre><code class="json"><span class="hl-2">{</span><br/><span class="hl-2"> </span><span class="hl-5">&quot;extends&quot;</span><span class="hl-2">: </span><span class="hl-3">&quot;@zthun/markdownlint-config/as-json.json&quot;</span><br/><span class="hl-2">}</span>
14
15
  </code><button type="button">Copy</button></pre>
15
16
 
@@ -4,7 +4,7 @@
4
4
  </code><button type="button">Copy</button></pre>
5
5
 
6
6
  <a id="md:usage" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Usage<a href="#md:usage" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><p>Use the prettier shared config convention.</p>
7
- <pre><code class="js"><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&#39;@zthun/prettier-config&#39;</span><span class="hl-2">);</span>
7
+ <pre><code class="js"><span class="hl-7">module</span><span class="hl-2">.</span><span class="hl-7">exports</span><span class="hl-2"> = </span><span class="hl-1">require</span><span class="hl-2">(</span><span class="hl-3">&quot;@zthun/prettier-config&quot;</span><span class="hl-2">);</span>
8
8
  </code><button type="button">Copy</button></pre>
9
9
 
10
10
  <p>That's it.</p>
@@ -1,5 +1,6 @@
1
1
  <!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>@zthun/stylelint-config-less | Janitor</title><meta name="description" content="Documentation for Janitor"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><link rel="icon" href="../janitor.svg" />
2
- </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_stylelint_config_less.html">@zthun/stylelint-config-less</a></li></ul><h1>Module @zthun/stylelint-config-less</h1></div><section class="tsd-panel tsd-typography"><a id="md:stylelint-config" class="tsd-anchor"></a><h1 class="tsd-anchor-link">StyleLint Config<a href="#md:stylelint-config" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>This is the shared stylelint configuration for zthun scoped projects using sass instead of raw css.</p>
2
+ </head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Janitor</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../index.html">Janitor</a></li><li><a href="_zthun_stylelint_config_less.html">@zthun/stylelint-config-less</a></li></ul><h1>Module @zthun/stylelint-config-less</h1></div><section class="tsd-panel tsd-typography"><a id="md:stylelint-config" class="tsd-anchor"></a><h1 class="tsd-anchor-link">StyleLint Config<a href="#md:stylelint-config" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h1><p>This is the shared stylelint configuration for zthun scoped projects using sass
3
+ instead of raw css.</p>
3
4
  <a id="md:getting-started" class="tsd-anchor"></a><h2 class="tsd-anchor-link">Getting Started<a href="#md:getting-started" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h2><pre><code class="sh"><span class="hl-0"># NPM</span><br/><span class="hl-1">npm</span><span class="hl-2"> </span><span class="hl-3">install</span><span class="hl-2"> </span><span class="hl-3">@zthun/stylelint-config-sass</span><span class="hl-2"> </span><span class="hl-4">--save-dev</span><br/><span class="hl-0"># Yarn</span><br/><span class="hl-1">yarn</span><span class="hl-2"> </span><span class="hl-3">add</span><span class="hl-2"> </span><span class="hl-3">@zthun/stylelint-config-sass</span><span class="hl-2"> </span><span class="hl-4">--dev</span>
4
5
  </code><button type="button">Copy</button></pre>
5
6