djlint / djLint

✨ HTML Template Linter and Formatter. Django - Jinja - Nunjucks - Handlebars - GoLang
https://djLint.com
GNU General Public License v3.0
686 stars 84 forks source link

chore(deps) Update linters #731

Closed renovate[bot] closed 1 year ago

renovate[bot] commented 1 year ago

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
eslint-plugin-import 2.27.5 -> 2.28.0 age adoption passing confidence
prettier (source) 3.0.0 -> 3.0.1 age adoption passing confidence

Release Notes

import-js/eslint-plugin-import (eslint-plugin-import) ### [`v2.28.0`](https://togithub.com/import-js/eslint-plugin-import/blob/HEAD/CHANGELOG.md#2280---2023-07-27) [Compare Source](https://togithub.com/import-js/eslint-plugin-import/compare/v2.27.5...v2.28.0) ##### Fixed - \[`no-duplicates`]: remove duplicate identifiers in duplicate imports (\[[#​2577](https://togithub.com/import-js/eslint-plugin-import/issues/2577)], thanks \[[@​joe-matsec](https://togithub.com/joe-matsec)]) - \[`consistent-type-specifier-style`]: fix accidental removal of comma in certain cases (\[[#​2754](https://togithub.com/import-js/eslint-plugin-import/issues/2754)], thanks \[[@​bradzacher](https://togithub.com/bradzacher)]) - \[Perf] `ExportMap`: Improve `ExportMap.for` performance on larger codebases (\[[#​2756](https://togithub.com/import-js/eslint-plugin-import/issues/2756)], thanks \[[@​leipert](https://togithub.com/leipert)]) - \[`no-extraneous-dependencies`]/TypeScript: do not error when importing inline type from dev dependencies (\[[#​1820](https://togithub.com/import-js/eslint-plugin-import/issues/1820)], thanks \[[@​andyogo](https://togithub.com/andyogo)]) - \[`newline-after-import`]/TypeScript: do not error when re-exporting a namespaced import (\[[#​2832](https://togithub.com/import-js/eslint-plugin-import/issues/2832)], thanks \[[@​laurens-dg](https://togithub.com/laurens-dg)]) - \[`order`]: partial fix for \[[#​2687](https://togithub.com/import-js/eslint-plugin-import/issues/2687)] (thanks \[[@​ljharb](https://togithub.com/ljharb)]) - \[`no-duplicates`]: Detect across type and regular imports (\[[#​2835](https://togithub.com/import-js/eslint-plugin-import/issues/2835)], thanks \[[@​benkrejci](https://togithub.com/benkrejci)]) - \[`extensions`]: handle `.` and `..` properly (\[[#​2778](https://togithub.com/import-js/eslint-plugin-import/issues/2778)], thanks \[[@​benasher44](https://togithub.com/benasher44)]) - \[`no-unused-modules`]: improve schema (thanks \[[@​ljharb](https://togithub.com/ljharb)]) - \[`no-unused-modules`]: report error on binding instead of parent export (\[[#​2842](https://togithub.com/import-js/eslint-plugin-import/issues/2842)], thanks \[[@​Chamion](https://togithub.com/Chamion)]) ##### Changed - \[Docs] \[`no-duplicates`]: fix example schema (\[[#​2684](https://togithub.com/import-js/eslint-plugin-import/issues/2684)], thanks \[[@​simmo](https://togithub.com/simmo)]) - \[Docs] \[`group-exports`]: fix syntax highlighting (\[[#​2699](https://togithub.com/import-js/eslint-plugin-import/issues/2699)], thanks \[[@​devinrhode2](https://togithub.com/devinrhode2)]) - \[Docs] \[`extensions`]: reference node ESM behavior (\[[#​2748](https://togithub.com/import-js/eslint-plugin-import/issues/2748)], thanks \[[@​xM8WVqaG](https://togithub.com/xM8WVqaG)]) - \[Refactor] \[`exports-last`]: use `array.prototype.findlastindex` (thanks \[[@​ljharb](https://togithub.com/ljharb)]) - \[Refactor] \[`no-anonymous-default-export`]: use `object.fromentries` (thanks \[[@​ljharb](https://togithub.com/ljharb)]) - \[Refactor] \[`no-unused-modules`]: use `array.prototype.flatmap` (thanks \[[@​ljharb](https://togithub.com/ljharb)])
prettier/prettier (prettier) ### [`v3.0.1`](https://togithub.com/prettier/prettier/blob/HEAD/CHANGELOG.md#301) [Compare Source](https://togithub.com/prettier/prettier/compare/3.0.0...3.0.1) [diff](https://togithub.com/prettier/prettier/compare/3.0.0...3.0.1) ##### Fix cursor positioning for a special case ([#​14812](https://togithub.com/prettier/prettier/pull/14812) by [@​fisker](https://togithub.com/fisker)) ```js // <|> is the cursor position /* Input */ // All messages are represented in JSON. // So, the prettier.py controls a subprocess which spawns "node {this_file}". import {<|> } from "fs" /* Prettier 3.0.0 */ // All messages are represented in JSON. // So, the prettier.py <|>controls a subprocess which spawns "node {this_file}". import {} from "fs" /* Prettier 3.0.1 */ // All messages are represented in JSON. // So, the prettier.py controls a subprocess which spawns "node {this_file}". import {<|>} from "fs" ``` ##### Fix plugins/estree.d.ts to make it a module ([#​15018](https://togithub.com/prettier/prettier/pull/15018) by [@​kingyue737](https://togithub.com/kingyue737)) Add `export {}` in `plugins/estree.d.ts` to fix the "File is not a module" error ##### Add parenthesis around leading multiline comment in return statement ([#​15037](https://togithub.com/prettier/prettier/pull/15037) by [@​auvred](https://togithub.com/auvred)) ```jsx // Input function fn() { return ( /** * @​type {...} */ expresssion ) } // Prettier 3.0.0 function fn() { return /** * @​type {...} */ expresssion; } // Prettier 3.0.1 function fn() { return ( /** * @​type {...} */ expresssion ); } ``` ##### Add support for Vue "Generic Components" ([#​15066](https://togithub.com/prettier/prettier/pull/15066) by [@​auvred](https://togithub.com/auvred)) https://blog.vuejs.org/posts/vue-3-3#generic-components ```vue ``` ##### Fix comments print in `IfStatement` ([#​15076](https://togithub.com/prettier/prettier/pull/15076) by [@​fisker](https://togithub.com/fisker)) ```js function a(b) { if (b) return 1; // comment else return 2; } /* Prettier 3.0.0 */ Error: Comment "comment" was not printed. Please report this error! /* Prettier 3.0.1 */ function a(b) { if (b) return 1; // comment else return 2; } ``` ##### Add missing type definition for `printer.preprocess` ([#​15123](https://togithub.com/prettier/prettier/pull/15123) by [@​so1ve](https://togithub.com/so1ve)) ```diff export interface Printer { // ... + preprocess?: + | ((ast: T, options: ParserOptions) => T | Promise) + | undefined; } ``` ##### Add missing `getVisitorKeys` method type definition for `Printer` ([#​15125](https://togithub.com/prettier/prettier/pull/15125) by [@​auvred](https://togithub.com/auvred)) ```tsx const printer: Printer = { print: () => [], getVisitorKeys(node, nonTraversableKeys) { return ["body"]; }, }; ``` ##### Add typing to support `readonly` array properties of AST Node ([#​15127](https://togithub.com/prettier/prettier/pull/15127) by [@​auvred](https://togithub.com/auvred)) ```tsx // Input interface TestNode { readonlyArray: readonly string[]; } declare const path: AstPath; path.map(() => "", "readonlyArray"); // Prettier 3.0.0 interface TestNode { readonlyArray: readonly string[]; } declare const path: AstPath; path.map(() => "", "readonlyArray"); // ^ Argument of type '"readonlyArray"' is not assignable to parameter of type '"regularArray"'. ts(2345) // Prettier 3.0.1 interface TestNode { readonlyArray: readonly string[]; } declare const path: AstPath; path.map(() => "", "readonlyArray"); ``` ##### Add space before unary minus followed by a function call ([#​15129](https://togithub.com/prettier/prettier/pull/15129) by [@​pamelalozano](https://togithub.com/pamelalozano)) ```less // Input div { margin: - func(); } // Prettier 3.0.0 div { margin: -func(); } // Prettier 3.0.1 div { margin: - func(); } ```

Configuration

📅 Schedule: Branch creation - "before 10pm on Sunday" in timezone America/Chicago, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.



This PR has been generated by Mend Renovate. View repository job log here.

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (f780bef) 95.34% compared to head (5c00d03) 95.35%. Report is 33 commits behind head on dev.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev #731 +/- ## ======================================= Coverage 95.34% 95.35% ======================================= Files 16 16 Lines 1032 1033 +1 Branches 278 278 ======================================= + Hits 984 985 +1 Misses 34 34 Partials 14 14 ``` | [Files Changed](https://app.codecov.io/gh/Riverside-Healthcare/djLint/pull/731?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Riverside-Healthcare) | Coverage Δ | | |---|---|---| | [src/djlint/formatter/condense.py](https://app.codecov.io/gh/Riverside-Healthcare/djLint/pull/731?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Riverside-Healthcare#diff-c3JjL2RqbGludC9mb3JtYXR0ZXIvY29uZGVuc2UucHk=) | `97.26% <ø> (ø)` | | | [src/djlint/settings.py](https://app.codecov.io/gh/Riverside-Healthcare/djLint/pull/731?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Riverside-Healthcare#diff-c3JjL2RqbGludC9zZXR0aW5ncy5weQ==) | `91.36% <ø> (ø)` | | | [src/djlint/formatter/indent.py](https://app.codecov.io/gh/Riverside-Healthcare/djLint/pull/731?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Riverside-Healthcare#diff-c3JjL2RqbGludC9mb3JtYXR0ZXIvaW5kZW50LnB5) | `98.55% <100.00%> (+0.01%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

christopherpickering commented 1 year ago

:tada: This PR is included in version 1.33.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: