linted 24.4.1-rc.1 → 24.4.1

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.
@@ -1,6 +1,8 @@
1
1
  {
2
- // v0.37.1
3
- // DOC: https://github.com/DavidAnson/markdownlint/blob/v0.37.4/doc/Rules.md
2
+ "$meta": {
3
+ "template": "0.37.2",
4
+ "rules": "https://github.com/DavidAnson/markdownlint/blob/v0.37.4/doc/Rules.md",
5
+ },
4
6
  // "$schema": "https://raw.githubusercontent.com/DavidAnson/markdownlint/v0.37.4/schema/markdownlint-config-schema.json",
5
7
  "heading-increment": true /* MD001 */,
6
8
  "heading-style": {
package/README.md CHANGED
@@ -1,8 +1,10 @@
1
1
  # [`linted`](https://www.npmjs.com/package/linted)
2
-
3
2
  [![NPM Publish (RELEASE)](https://github.com/jimmy-zhening-luo/linted/actions/workflows/RELEASE.yml/badge.svg)](https://github.com/jimmy-zhening-luo/linted/actions/workflows/RELEASE.yml)
4
3
 
5
- ___DO NOT USE - DOCUMENTATION IS SIGNIFICANTLY OUTDATED AS OF AUGUST 4, 2024___
4
+ > [!CAUTION]
5
+ > ___DO NOT USE - DOCUMENTATION IS SIGNIFICANTLY OUTDATED AS OF AUGUST 4, 2024___
6
+
7
+ ---
6
8
 
7
9
  [ESLint](https://eslint.org) mono-plugin bundler with strict, opinionated defaults for (Stylistic) JavaScript, TypeScript, Svelte, HTML, Tailwind/CSS, JSON, JSONC, YAML, and Mocha.
8
10
 
@@ -16,6 +18,8 @@ ___DO NOT USE - DOCUMENTATION IS SIGNIFICANTLY OUTDATED AS OF AUGUST 4, 2024___
16
18
  ## Languages
17
19
 
18
20
  ### Web
21
+ > [!NOTE]
22
+ > _See language support __[roadmap](#roadmap).___
19
23
 
20
24
  - __[JavaScript](https://developer.mozilla.org/en-US/docs/Web/JavaScript):__ [`@stylistic`](https://eslint.style) + [`eslint`](https://eslint.org)
21
25
  - __[TypeScript](https://www.typescriptlang.org):__ [`@typescript-eslint`](https://typescript-eslint.io/) + [`@stylistic`](https://eslint.style) + [`eslint`](https://eslint.org)
@@ -30,20 +34,13 @@ ___DO NOT USE - DOCUMENTATION IS SIGNIFICANTLY OUTDATED AS OF AUGUST 4, 2024___
30
34
  ### Library
31
35
 
32
36
  - __[Mocha](https://mochajs.org/):__ [`eslint-plugin-mocha`](https://github.com/lo1tuma/eslint-plugin-mocha) + [`@typescript-eslint`](https://typescript-eslint.io/) + [`@stylistic`](https://eslint.style) + [`eslint`](https://eslint.org)
33
- -
34
-
35
- <br />
36
-
37
- _See language support __[roadmap](#roadmap).___
38
37
 
39
38
  ## Features
40
39
 
41
40
  ### Zero-Dependency
42
-
43
41
  No need to install 17 plugins and 12 parsers: each language's latest plugin is bundled and configured.
44
42
 
45
43
  ### Zero-Config
46
-
47
44
  No need to remember each plugin's `parserOptions`; you won't have to do _this_ just to enable Svelte linting:
48
45
 
49
46
  ```javascript
@@ -84,8 +81,6 @@ export default linted();
84
81
 
85
82
  ### Total Control via Optional Arguments
86
83
 
87
- ___WIP for v14.1, currently inaccurate___.
88
-
89
84
  - `includes` (scoped [`glob patterns`](https://code.visualstudio.com/docs/editor/glob-patterns))
90
85
  - `ignores` (global [`glob patterns`](https://code.visualstudio.com/docs/editor/glob-patterns) and other options)
91
86
  - `overrides` (scoped rule statements)
@@ -155,11 +150,9 @@ linted(
155
150
  ```
156
151
 
157
152
  ## Limitation
158
-
159
153
  In __TypeScript__ projects, [`skipLibCheck`](https://www.typescriptlang.org/tsconfig/#skipLibCheck) must be `true`.
160
154
 
161
155
  ### Enable `skipLibCheck`
162
-
163
156
  By default, `skipLibCheck` is `false`. To set it to `true`:
164
157
 
165
158
  #### `tsconfig.json`
@@ -186,9 +179,9 @@ tsc --skipLibCheck
186
179
  npm i -D eslint@^8.57 linted
187
180
  ```
188
181
 
189
- 2. Create `eslint.config.js` in your project root.
182
+ 1. Create `eslint.config.js` in your project root.
190
183
 
191
- 3. In `eslint.config.js`:
184
+ 1. In `eslint.config.js`:
192
185
  + Import function `linted`.
193
186
 
194
187
  ```javascript
@@ -211,17 +204,13 @@ tsc --skipLibCheck
211
204
 
212
205
  ### v11
213
206
 
214
- #### Mocha
215
-
216
- - Mocha
217
-
218
- #### Tailwind PostCSS
207
+ #### Tailwind
219
208
 
220
209
  - [Tailwind](https://github.com/francoismassart/eslint-plugin-tailwindcss)
221
210
 
222
211
  - [CSS](https://ota-meshi.github.io/eslint-plugin-css/)
223
212
 
224
- #### HTML Connectors
213
+ #### HTML Embeds
225
214
 
226
215
  - [Embedded TypeScript](https://github.com/BenoitZugmeyer/eslint-plugin-html)
227
216
 
@@ -244,29 +233,20 @@ tsc --skipLibCheck
244
233
  ## Rule Logic (Advanced)
245
234
 
246
235
  ### What is `scope`?
247
-
248
236
  Each `scope` maps to a unique `language`:
249
237
 
250
238
  - __`js`:__ `JavaScript`
251
-
252
239
  - __`ts`:__ `TypeScript`
253
-
254
240
  - __`svelte`:__ `Svelte`
255
-
256
241
  - __`html`:__ `HTML`
257
-
258
242
  - __`json`:__ `JSON`
259
-
260
243
  - __`jsonc`:__ `JSONC`
261
-
262
244
  - __`yml`:__ `YAML`
263
245
 
264
246
  ### Rules
265
-
266
247
  Each `scope` supports:
267
248
 
268
249
  - all base ESLint rules
269
-
270
250
  - all rules from its `language`'s [__plugins__](#languages)
271
251
 
272
252
  #### Default Rules
@@ -274,29 +254,21 @@ Each `scope` supports:
274
254
  - Each `language` has a set of default rules.
275
255
 
276
256
  #### Language-Aggregate `scope`
277
-
278
257
  A `language` can be an extension of or depend on another `language`.
279
258
 
280
259
  For example:
281
260
 
282
261
  - TypeScript extends JavaScript
283
-
284
262
  - Svelte depends on TypeScript (which extends JavaScript)
285
263
 
286
264
  For such a `language`, its `scope`'s default rules are aggregated with the default rules of extended or consumed `language`s by `scope` precedence:
287
265
 
288
266
  - __`js`:__ `js`
289
-
290
267
  - __`ts`:__ `js` < `ts`
291
-
292
268
  - __`svelte`:__ `js` < `ts` < `svelte`
293
-
294
269
  - __`html`:__ `html`
295
-
296
270
  - __`json`:__ `json`
297
-
298
271
  - __`jsonc`:__ `json` < `jsonc`
299
-
300
272
  - __`yml`:__ `yml`
301
273
 
302
274
  ### Files
@@ -304,19 +276,15 @@ For such a `language`, its `scope`'s default rules are aggregated with the defau
304
276
  #### Global Ignores
305
277
 
306
278
  ##### `.gitignore`
307
-
308
279
  By default, `linted` ignores all files in `.gitignore`. This behavior can be disabled.
309
280
 
310
281
  ##### `package-lock.json`
311
-
312
282
  `**/*.package-lock.json` is always skipped. _This cannot be overriden._
313
283
 
314
284
  ##### `ignores`
315
-
316
285
  Additional glob patterns supplied if matched by a file will skip linting that file, even if a scope pattern matches the file.
317
286
 
318
287
  #### Scoped Includes
319
-
320
288
  Files specified in `scope` are appended to the following default files:
321
289
 
322
290
  ```javascript
@@ -354,7 +322,6 @@ Files specified in `scope` are appended to the following default files:
354
322
  #### Scope Conflict
355
323
 
356
324
  - If a given file matches more than one `scope` glob, then the set of all matching `scope`s' rules are applied to the file.
357
-
358
325
  - If any rule is specified in more than one `scope` matching a given file, the specifies a rule, then the highest-precedence `scope`'s rule specification wins.
359
326
 
360
327
  ##### Scope Precedence (low to high)
@@ -371,17 +338,14 @@ ignores (global)
371
338
  ```
372
339
 
373
340
  ### Override
374
-
375
341
  Overrides are per-__scope.__
376
342
 
377
343
  #### Example
378
-
379
344
  `overrideTs` rules apply to files which:
380
345
 
381
346
  - ✅ ONLY match scope `ts`.
382
-
383
347
  - ✅ match scope `ts` and any number of lower precedence scopes (e.g. `js`).
384
-
385
- `overrideTs` rules do __NOT__ apply to files which:
386
-
348
+ > [!NOTE]
349
+ > `overrideTs` rules do __NOT__ apply to files which:
350
+ > - TBD
387
351
  - ❌ match scope `ts` and at least one higher precedence scope (e.g. `svelte`), even if the higher precedence scope includes `ts` language default rules (e.g. `svelte` includes `ts` default rules, but NOT `overrideTs` rules).
package/package.json CHANGED
@@ -1,36 +1,11 @@
1
1
  {
2
- "_schemaVersion": "22.13.1",
2
+ "$template": "22.13.4",
3
3
  "name": "linted",
4
- "version": "24.4.1-rc.1",
4
+ "version": "24.4.1",
5
5
  "description": "ESLint mono-plugin bundler with strict, opinionated defaults for (Stylistic) JavaScript, TypeScript, Svelte, HTML, Tailwind/CSS, JSON, JSONC, YAML, and Mocha.",
6
- "keywords": [
7
- "eslint",
8
- "eslint-config",
9
- "eslint-plugin",
10
- "linter",
11
- "formatter",
12
- "typescript",
13
- "javascript",
14
- "stylistic",
15
- "svelte",
16
- "sveltekit",
17
- "html",
18
- "css",
19
- "mocha",
20
- "tailwindcss",
21
- "json",
22
- "jsonc",
23
- "yaml"
24
- ],
25
6
  "repository": "github:jimmy-zhening-luo/linted",
26
- "homepage": "https://github.com/jimmy-zhening-luo/linted#readme",
27
- "bugs": "https://github.com/jimmy-zhening-luo/linted/issues",
28
7
  "license": "MIT",
29
8
  "private": false,
30
- "publishConfig": {
31
- "access": "public",
32
- "tag": "next"
33
- },
34
9
  "type": "module",
35
10
  "main": "dist/index.js",
36
11
  "types": "dist/index.d.ts",
@@ -62,8 +37,8 @@
62
37
  }
63
38
  },
64
39
  "dependencies": {
65
- "@eslinted/core": "15.2.8",
66
- "@eslinted/defaults": "4.10.5",
40
+ "@eslinted/core": "15.2.9",
41
+ "@eslinted/defaults": "4.10.6",
67
42
  "@html-eslint/eslint-plugin": "0.33.1",
68
43
  "@html-eslint/parser": "0.33.0",
69
44
  "@stylistic/eslint-plugin": "2.13.0",
@@ -138,10 +113,33 @@
138
113
  "predeploy": "npm test",
139
114
  "deploy": ""
140
115
  },
116
+ "publishConfig": {
117
+ "access": "public",
118
+ "tag": "next"
119
+ },
141
120
  "mocha": {
142
121
  "spec": [
143
122
  "dist/**/*.spec.js"
144
123
  ]
145
124
  },
125
+ "keywords": [
126
+ "eslint",
127
+ "eslint-config",
128
+ "eslint-plugin",
129
+ "linter",
130
+ "formatter",
131
+ "typescript",
132
+ "javascript",
133
+ "stylistic",
134
+ "svelte",
135
+ "sveltekit",
136
+ "html",
137
+ "css",
138
+ "mocha",
139
+ "tailwindcss",
140
+ "json",
141
+ "jsonc",
142
+ "yaml"
143
+ ],
146
144
  "author": "Jimmy Zhening Luo <1450044+jimmy-zhening-luo@users.noreply.github.com> (https://jimm.my/)"
147
145
  }