profile
viewpoint

EmmanuelDemey/eslint-plugin-angular 609

ESLint plugin for AngularJS applications

remcohaszing/babel-plugin-transform-react-class-to-function 16

A Babel 7 plugin which transforms React component classes into functions

remcohaszing/axios-test-instance 7

Test NodeJS backends using Axios

itslanguage/itslanguage-js 1

The JavaScript SDK for ITSLanguage.

remcohaszing/dotfiles 1

My personal dotfiles

dcentralize/eslint-config-d-centralize 0

Shareable ESLint configuration used at d-centralize.

remcohaszing/angular-rh-format 0

String formatting in AngularJS

remcohaszing/atom 0

Atom file-specific icons for improved visual grepping.

remcohaszing/awesome-babel 0

A list of awesome Babel plugins, presets, etc.

remcohaszing/awesome-eslint 0

A list of awesome ESLint plugins, configs, etc.

issue openedSoontao/odata-v4-parser

Support OData v4.01

Currently this package parses OData v4.0 syntax. From what I can tell OData v4.01 supports new functions and should be non-breaking.

created time in a day

issue openedsequelize/sequelize

Invalid query filtering Postgres JSON data

Issue Description

Postgres functions are applied wrong on JSON column data.

What are you doing?

I have the following table generated by Sequelize:

Column Type Modifiers
id integer not null
data json not null

and the following data:

id data
1 {"name":"Foo"}
2 {"name":"Bar"}

I tried to search the data in a case insensitive manner by using lower.

import { fn, Op, where } from 'sequelize';

import { Resource } from '../models';

async function main() {
  return Resource.findAll({
    where: where(fn('lower', 'data.name'), 'foo'),
  });
}

main();

However, this yields no results.

What do you expect to happen?

I wanted Foo!

I expected the main function to return the entity whose name is Foo.

This result could be achieved using the following query:

SELECT "Resource"."data" FROM "Resource" AS "Resource" WHERE lower(data ->> 'firstName') = 'foo'

What is actually happening?

Nothing was returned.

The generated query looks like this:

SELECT "Resource"."data" FROM "Resource" AS "Resource" WHERE data #>>'{tolower(firstName)}' = 'foo'

Additional context

Add any other context or screenshots about the feature request here.

Environment

  • Sequelize version: 5.22.3 (I tried upgrading to the latest, which yields the same issue)
  • Node.js version: 14.12.0
  • Operating System: Pop!_OS 20.04

Issue Template Checklist

<!-- Please answer the questions below. If you don't, your issue may be closed. -->

How does this problem relate to dialects?

  • [ ] I think this problem happens regardless of the dialect.
  • [x] I think this problem happens only for the following dialect(s): postgres
  • [ ] I don't know, I was using PUT-YOUR-DIALECT-HERE, with connector library version XXX and database version XXX

Would you be willing to resolve this issue by submitting a Pull Request?

  • [ ] Yes, I have the time and I know how to start.
  • [ ] Yes, I have the time but I don't know how to start, I would need guidance.
  • [ ] No, I don't have the time, although I believe I could do it if I had the time...
  • [x] No, I don't have the time and I wouldn't even know how to start.

created time in 2 days

fork remcohaszing/sequelize-typescript

Decorators and some other features for sequelize

fork in 2 days

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],+      },+    ],+  },+  defaultOptions: ['always'],+  create(context) {+    const sourceCode = context.getSourceCode();++    if (context.options[0] === 'never') {+      return {+        TSTypeReference(node): void {+          const typeName = node.typeName as TSESTree.Identifier;+          if (typeName.name !== 'Record') {+            return;+          }++          const params = node.typeParameters?.params;+          if (params?.length !== 2) {+            return;+          }++          context.report({+            node,+            messageId: 'preferIndexSignature',+            fix(fixer) {+              const key = sourceCode.getText(params[0]);+              const type = sourceCode.getText(params[1]);+              return fixer.replaceTextRange(+                node.range,+                `{ [key: ${key}]: ${type} }`,+              );+            },+          });+        },+      };+    }++    /**+     * Convert an index signature node to record code as string.+     */+    function toRecord(node: TSESTree.TSIndexSignature): string {+      const parameter = node.parameters[0] as TSESTree.Identifier;

I did this now, but it did cause code coverage to drop as I couldn’t find a situation that causes the index signature parameters to have a length other than 0, be of anohter type than an identifier, or not have a type annotation.

remcohaszing

comment created time in 3 days

PullRequestReviewEvent

push eventremcohaszing/typescript-eslint

Remco Haszing

commit sha e2af4bd9035d568efa6872e5f29a1f3868e1481f

fix(eslint-plugin): [consistent-indexed-object-style]: handle a syntax error

view details

push time in 3 days

push eventremcohaszing/typescript-eslint

Remco Haszing

commit sha 2e7c6b8f737530b77c905702af45ad9dcaebf155

refactor(eslint-plugin): [consistent-indexed-object-style] make rule more type safe

view details

push time in 3 days

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],

I changed it to record and index-signature respectively, because I think the always prefix is unnecessary. Let me know if you still want me to change it.

remcohaszing

comment created time in 3 days

PullRequestReviewEvent

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],+      },+    ],+  },+  defaultOptions: ['always'],+  create(context) {+    const sourceCode = context.getSourceCode();++    if (context.options[0] === 'never') {+      return {+        TSTypeReference(node): void {+          const typeName = node.typeName as TSESTree.Identifier;+          if (typeName.name !== 'Record') {+            return;+          }++          const params = node.typeParameters?.params;+          if (params?.length !== 2) {+            return;+          }++          context.report({+            node,+            messageId: 'preferIndexSignature',+            fix(fixer) {+              const key = sourceCode.getText(params[0]);+              const type = sourceCode.getText(params[1]);+              return fixer.replaceTextRange(+                node.range,+                `{ [key: ${key}]: ${type} }`,+              );+            },+          });+        },+      };+    }++    /**+     * Convert an index signature node to record code as string.+     */+    function toRecord(node: TSESTree.TSIndexSignature): string {+      const parameter = node.parameters[0] as TSESTree.Identifier;+      const key = sourceCode.getText(parameter.typeAnnotation!.typeAnnotation);+      const value = sourceCode.getText(node.typeAnnotation!.typeAnnotation);

I added a test and was actually able to deduplicate even more logic now.

remcohaszing

comment created time in 3 days

PullRequestReviewEvent

push eventremcohaszing/typescript-eslint

Remco Haszing

commit sha 00d655c4f7a3d51786485f73190063527f512f17

fix(eslint-plugin): [consistent-indexed-object-style] Handle invalid syntax The newly handled syntax isn’t valid TypeScript syntax, but the TypeScript parser does parse it and it’s passed to ESLint.

view details

Remco Haszing

commit sha 3c92d20f1edec95a2aac664a6536b14debd5a0e2

refactor(eslint-plugin): [consistent-indexed-object-style] clarify options `always` has been renamed to `record`. `never` has been renamed to `indexed-signature`.

view details

push time in 3 days

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],+      },+    ],+  },+  defaultOptions: ['always'],+  create(context) {+    const sourceCode = context.getSourceCode();++    if (context.options[0] === 'never') {+      return {+        TSTypeReference(node): void {+          const typeName = node.typeName as TSESTree.Identifier;+          if (typeName.name !== 'Record') {+            return;+          }++          const params = node.typeParameters?.params;+          if (params?.length !== 2) {+            return;+          }++          context.report({+            node,+            messageId: 'preferIndexSignature',+            fix(fixer) {+              const key = sourceCode.getText(params[0]);+              const type = sourceCode.getText(params[1]);+              return fixer.replaceTextRange(+                node.range,+                `{ [key: ${key}]: ${type} }`,+              );+            },+          });+        },+      };+    }++    /**+     * Convert an index signature node to record code as string.+     */+    function toRecord(node: TSESTree.TSIndexSignature): string {+      const parameter = node.parameters[0] as TSESTree.Identifier;

The return type is used in the fixer. Your suggestion would potentially make the autofixer return undefined, which actually causes syntax errors. The check would need to happen before the node is even reported. I tried to look for such a situation, but I couldn’t find any.

remcohaszing

comment created time in 5 days

PullRequestReviewEvent

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],+      },+    ],+  },+  defaultOptions: ['always'],+  create(context) {+    const sourceCode = context.getSourceCode();++    if (context.options[0] === 'never') {+      return {+        TSTypeReference(node): void {+          const typeName = node.typeName as TSESTree.Identifier;+          if (typeName.name !== 'Record') {+            return;+          }++          const params = node.typeParameters?.params;+          if (params?.length !== 2) {+            return;+          }++          context.report({+            node,+            messageId: 'preferIndexSignature',+            fix(fixer) {+              const key = sourceCode.getText(params[0]);+              const type = sourceCode.getText(params[1]);+              return fixer.replaceTextRange(+                node.range,+                `{ [key: ${key}]: ${type} }`,+              );+            },+          });+        },+      };+    }++    /**+     * Convert an index signature node to record code as string.+     */+    function toRecord(node: TSESTree.TSIndexSignature): string {+      const parameter = node.parameters[0] as TSESTree.Identifier;+      const key = sourceCode.getText(parameter.typeAnnotation!.typeAnnotation);+      const value = sourceCode.getText(node.typeAnnotation!.typeAnnotation);

The rule didn’t crash on these rules. Do you want me to add test cases for T1 and T3 anyway?

How is T2 invalid? This looks like the most basic case handled by this rule.

remcohaszing

comment created time in 5 days

PullRequestReviewEvent

Pull request review commenttypescript-eslint/typescript-eslint

feat(eslint-plugin): add `consistent-indexed-object-style` rule

+import { createRule } from '../util';+import {+  AST_NODE_TYPES,+  TSESTree,+} from '@typescript-eslint/experimental-utils';++export default createRule({+  name: 'consistent-indexed-object-style',+  meta: {+    type: 'suggestion',+    docs: {+      description: 'Enforce or disallow the use of the record type',+      category: 'Stylistic Issues',+      // too opinionated to be recommended+      recommended: false,+    },+    messages: {+      preferRecord: 'A record is preferred over an index signature',+      preferIndexSignature: 'An index signature is preferred over a record.',+    },+    fixable: 'code',+    schema: [+      {+        enum: ['always', 'never'],+      },+    ],+  },+  defaultOptions: ['always'],+  create(context) {+    const sourceCode = context.getSourceCode();++    if (context.options[0] === 'never') {+      return {+        TSTypeReference(node): void {+          const typeName = node.typeName as TSESTree.Identifier;

Good catch.

remcohaszing

comment created time in 5 days

PullRequestReviewEvent

push eventremcohaszing/typescript-eslint

Remco Haszing

commit sha 186b1932202fac37780f198c2d9790b904d72d9d

fix(eslint-plugin): [consistent-indexed-object-style] handle namespace types

view details

push time in 5 days

push eventremcohaszing/typescript-eslint

Ethan Setnik

commit sha ffdfade106d602bcc12b074bdfa489e9f661491e

fix(eslint-plugin): handle missing message IDs in eslint v5/v6 (#2461)

view details

Brad Zacher

commit sha bfe255fde0cb5fe5e32c02eb5ba35d27fb23d9ea

feat(eslint-plugin): [no-shadow] add option `ignoreFunctionTypeParameterNameValueShadow` (#2470)

view details

Gabriel Cangussu

commit sha 20a7dcc808a39cd447d6e52fc5a1e1373d7122e9

fix(scope-manager): fallback to lib 'esnext' or 'es5' when ecma version is unsupported (#2474)

view details

Brad Zacher

commit sha 6595cf1d458edd481507b40b78173eb49f5991b1

docs: reorder FAQ (#2485)

view details

Brad Zacher

commit sha cee9be708f1b19cefc4eea5af2a6a88eb4f9186b

docs: add link to v4 release notes to the changelogs (#2487) Some users use CHANGELOG.md as the source of truth for releases and don't check the github releases page. We should probably delete these files and just have everything in the GH releases page. This adds a link to the v4 releases page and adds a disclaimer to the top of the file pointing at the releases page.

view details

Brad Zacher

commit sha 36305df74b3c26b60364f7ec13390be492b4b2ec

feat(eslint-plugin): add extension rule `no-loop-func` (#2490)

view details

Brad Zacher

commit sha 9d8b4c479c98623e4198aa07639321929a8a876f

fix(scope-manager): support rest function type parameters (#2491) Fixes #2449

view details

Brad Zacher

commit sha a2686c04293ab9070c1500a0dab7e205bd1fa9d2

fix(scope-manager): support tagged template string generic type parameters (#2492)

view details

Brad Zacher

commit sha a40f54c39d59096a0d12a492807dcd52fbcdc384

fix(scope-manager): support type predicates (#2493) Fixes #2462

view details

Brad Zacher

commit sha 916e95a505689746dda38a67148c95cc7d207d9f

fix(scope-manager): treat type imports as both values and types (#2494) Fixes #2453

view details

Brad Zacher

commit sha 4d3ce5f696985389bf53a31d62766041c703c70c

fix(eslint-plugin): [no-unused-vars] properly handle ambient declaration exports (#2496)

view details

Brad Zacher

commit sha 95f6bf4818cdec48a0583bf82f928c598af22736

fix(scope-manager): correctly handle inferred types in nested type scopes (#2497)

view details

Brad Zacher

commit sha f887ab51f58c1b3571f9a14832864bc0ca59623f

feat(scope-manager): add support for JSX scope analysis (#2498) Fixes #2455 And part of #2477 JSX is a first-class citizen of TS, so we should really support it as well. I was going to just rely upon `eslint-plugin-react`'s patch lint rules (`react/jsx-uses-react` and `react/jsx-uses-vars`), but that leaves gaps in our tooling. For example #2455, `consistent-type-imports` makes assumptions and can create invalid fixes for react without this change. We could add options to that lint rule for the factory, but that is kind-of a sub-par experience and future rule authors will likely run into similar problems. - Adds full scope analysis support for JSX. - Adds two new `parserOption`: - `jsxPragma` - the name to use for constructing JSX elements. Defaults to `"React"`. Will be auto detected from the tsconfig. - `jsxFragmentName` - the name that unnamed JSX fragments use. Defaults to `null` (i.e. assumes `React.Fragment`). Will be auto detected from the tsconfig.

view details

Brad Zacher

commit sha bb3e9d66e3821f37633d8c8077d807418c3f6f18

docs(eslint-plugin): [no-redeclare] clearly document type/variable redeclare case (#2500) Addresses #2477

view details

Brad Zacher

commit sha eb3f6e39391d62ac424baa305a15e61806b2fd65

fix(scope-manager): add `const` as a global type variable (#2499)

view details

Daniel Nixon

commit sha 3b0e58f8b06975539f574edabaae5911f5db38a8

docs: fix broken TOC link (#2501)

view details

Brad Zacher

commit sha 5afeeab24ad013142f2431750f24e6085d0a6f3a

fix(eslint-plugin): [no-use-before-define] false positive with jsx pragma reference (#2503) Fixes #2502

view details

Brad Zacher

commit sha cdb9807a5a368a136856cd03048b68e0f2dfb405

fix(scope-manager): don't create references for intrinsic JSX elements (#2504)

view details

Gaon Kim

commit sha 2ada5aff1ef37bc260d7a0eaafe9ff04f8a08fe4

fix(eslint-plugin): [typedef] false positive for rest parameter with array destructuring (#2441)

view details

Brad Zacher

commit sha 3d07a99faa0a5fc1b44acdb43ddbfc90a5105833

fix(eslint-plugin): [no-unused-vars] correct detection of unused vars in a declared module with `export =` (#2505) If a `declare module` has an `export =` in its body, then TS will only export that. If it doesn't have an `export =`, then all things are ambiently exported. This adds handling to correctly detect this case.

view details

push time in 5 days

issue commentjest-community/eslint-plugin-jest

Rule proposal: enforce describe blocks match module exports

I like it!

Cool! I thought you’d either love or hate the idea.


Actually this is very similar to import/named.

I believe their logic to process the referenced module is in eslint-module-utils.

remcohaszing

comment created time in 8 days

issue openedhelm/helm

Print shorter date notations when using helm ls

helm ls gives the following output:

$ helm ls
NAME                NAMESPACE  REVISION  UPDATED                                  STATUS    CHART              APP VERSION
review-1292-vq6732  review     1         2020-09-10 16:04:41.646382274 +0000 UTC  deployed  appsemble-0.13.13  0.13.13    
review-1359-i2leh9  review     1         2020-09-22 12:38:16.73325296 +0000 UTC   deployed  appsemble-0.13.15  0.13.15    
review-1373-0y7trv  review     1         2020-09-23 13:51:08.30934844 +0000 UTC   deployed  appsemble-0.13.15  0.13.15

At first I wanted to report an issue to not omit trailing zero’s in the updated datetime value, as the inconsistent clumn output triggers me. Then I concluded the information is not relevant. Helm deployments tend to take much longer than a nanosecond. I think it’s fair to round the time value to seconds. Also AFAIK the time zone is always +0000 UTC.

I propose to omit decimals from the seconds in the time format and omit +0000 from the time zone offset, as UTC is clear enough. So the output of helm ls given the situation above would become:

$ helm ls
NAME                NAMESPACE  REVISION  UPDATED                  STATUS    CHART              APP VERSION
review-1292-vq6732  review     1         2020-09-10 16:04:41 UTC  deployed  appsemble-0.13.13  0.13.13    
review-1359-i2leh9  review     1         2020-09-22 12:38:16 UTC  deployed  appsemble-0.13.15  0.13.15    
review-1373-0y7trv  review     1         2020-09-23 13:51:08 UTC  deployed  appsemble-0.13.15  0.13.15

This fixes the weird looking column caused by rounding the second decimals, and makes the rows shorter, meaning they are more usable on smaller screens.

Alternatively the UTC part could be moved into the UPDATED label, making the output even narrower.

$ helm ls
NAME                NAMESPACE  REVISION  UPDATED (UTC)        STATUS    CHART              APP VERSION
review-1292-vq6732  review     1         2020-09-10 16:04:41  deployed  appsemble-0.13.13  0.13.13
review-1359-i2leh9  review     1         2020-09-22 12:38:16  deployed  appsemble-0.13.15  0.13.15
review-1373-0y7trv  review     1         2020-09-23 13:51:08  deployed  appsemble-0.13.15  0.13.15

created time in 8 days

pull request commentaxios/axios

Updating axios in types to be lower case

It’s non breaking.

Is it actually? For the default export I agree, but I believe the renaming of the exported const technically is a small breakage. But that one is easily fixed and should only affect error reporting during type checking without any functional change.

Yes, first the value is declared, which is an internal detail. Next it’s exported as default, for which the name doesn’t matter.

All this affects is how TypeScript editors will autocomplete the default import. Type validity is untouched.

remcohaszing

comment created time in 9 days

pull request commentaxios/axios

Updating axios in types to be lower case

@jasonsaayman @chinesedfan I noticed you have been tagging pull requests for v0.20.1. Can this be included? It’s non breaking.

remcohaszing

comment created time in 9 days

pull request commentaxios/axios

Fixing node types

This is non breaking.

remcohaszing

comment created time in 9 days

issue openedvscode-icons/vscode-icons

[Icon Request] Support for ABNF

  • [x] I'm sure this issue is not a duplicate.

  • [x] I'm submitting an icon request:

    • Type: extension
    • Icon Name: abnf
    • Sample original Icon: There is no official logo
    • Extensions: .abnf
  • Language Extensions: https://marketplace.visualstudio.com/items?itemName=forivall.abnf

  • More info:

    ABNF is a format which is used to describe other formats.

    • https://tools.ietf.org/html/std68
    • https://en.wikipedia.org/wiki/Augmented_Backus%E2%80%93Naur_form

created time in 10 days

issue openedjest-community/eslint-plugin-jest

Rule proposal: enforce describe blocks match module exports

I like to write my tests, so each describe block matches an export of the similar named module.

For example, given the following module:

// module.js
export function foo() {}

export const bar = () => {}

I would like to enforce the following layout for a test file:

// module.test.js
describe('foo' () => {});

describe('bar' () => {});

I would like to propose a rule that verifies the name of a top-level describe block match the name of an export in the module with the same name, minus the .test / .spec postfix.

created time in 10 days

pull request commentaxios/axios

Fixing node types

@Guillaume-Mayer

Out of curiosity, what is the matter with importing the DOM lib in a node environment? Since it's just typing.

Although these types currently don’t conflict, they might in the future. For a practical example, the types of dom and webworker do conflict, so they can’t be combined within the same project.

TypeScript should help by providing type information. If you’re working on a TypeScript project and somehow one types document.createElement('') in a file, one would expect TypeScript to fail over this.

Also a project that claims to work in a Node environment, shouldn’ require the user to specify they’re using a DOM environment, which is the current situation with Axios.

remcohaszing

comment created time in 17 days

PR opened CreativeBulma/bulma-tagsinput

Set the main field to the dist file

The main field is set to the dist file, so it can be consumed using NodeJS, for example by jest. The newly added module field references the original source. This is consumed by module bundlers.

+2 -1

0 comment

1 changed file

pr created time in 21 days

create barnchremcohaszing/bulma-tagsinput

branch : fix-main

created branch time in 21 days

issue commentandyholmes/gnome-shell-extension-gsconnect

[Android 10/Q] Clipboard sync doesn't work

The Android issue can be found here.

Dashon1

comment created time in 21 days

PR closed remcohaszing/cordova-webpack

Bump lodash from 4.17.15 to 4.17.19 dependencies

Bumps lodash from 4.17.15 to 4.17.19. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/lodash/lodash/releases">lodash's releases</a>.</em></p> <blockquote> <h2>4.17.16</h2> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/lodash/lodash/commit/d7fbc52ee0466a6d248f047b5d5c3e6d1e099056"><code>d7fbc52</code></a> Bump to v4.17.19</li> <li><a href="https://github.com/lodash/lodash/commit/2e1c0f22f425e9c013815b2cd7c2ebd51f49a8d6"><code>2e1c0f2</code></a> Add npm-package</li> <li><a href="https://github.com/lodash/lodash/commit/1b6c282299f4e0271f932b466c67f0f822aa308e"><code>1b6c282</code></a> Bump to v4.17.18</li> <li><a href="https://github.com/lodash/lodash/commit/a370ac81408de2da77a82b3c4b61a01a3b9c2fac"><code>a370ac8</code></a> Bump to v4.17.17</li> <li><a href="https://github.com/lodash/lodash/commit/1144918f3578a84fcc4986da9b806e63a6175cbb"><code>1144918</code></a> Rebuild lodash and docs</li> <li><a href="https://github.com/lodash/lodash/commit/3a3b0fd339c2109563f7e8167dc95265ed82ef3e"><code>3a3b0fd</code></a> Bump to v4.17.16</li> <li><a href="https://github.com/lodash/lodash/commit/c84fe82760fb2d3e03a63379b297a1cc1a2fce12"><code>c84fe82</code></a> fix(zipObjectDeep): prototype pollution (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4759">#4759</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/e7b28ea6cb17b4ca021e7c9d66218c8c89782f32"><code>e7b28ea</code></a> Sanitize sourceURL so it cannot affect evaled code (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4518">#4518</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/0cec225778d4ac26c2bac95031ecc92a94f08bbb"><code>0cec225</code></a> Fix lodash.isEqual for circular references (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4320">#4320</a>) (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4515">#4515</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/94c3a8133cb4fcdb50db72b4fd14dd884b195cd5"><code>94c3a81</code></a> Document matches* shorthands for over* methods (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4510">#4510</a>) (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4514">#4514</a>)</li> <li>Additional commits viewable in <a href="https://github.com/lodash/lodash/compare/4.17.15...4.17.19">compare view</a></li> </ul> </details> <details> <summary>Maintainer changes</summary> <p>This version was pushed to npm by <a href="https://www.npmjs.com/~mathias">mathias</a>, a new releaser for lodash since your current version.</p> </details> <br />

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


<details> <summary>Dependabot commands and options</summary> <br />

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

You can disable automated security fix PRs for this repo from the Security Alerts page.

</details>

+3 -3

0 comment

1 changed file

dependabot[bot]

pr closed time in 23 days

pull request commentDefinitelyTyped/DefinitelyTyped

Fix types for CSS modules

This PR isn’t abandoned. I’m still waiting for a code reviewer.

remcohaszing

comment created time in 24 days

push eventremcohaszing/typescript-eslint

Brad Zacher

commit sha 6f397df42cbcf05c10f304c9bbfdae4803aa0ce2

chore: update issue templates (#2397)

view details

Brad Zacher

commit sha cab7c4d402f0d0d3371c10e56f755b57aebf6997

chore: fix typo in issue templates

view details

Alec Custer

commit sha 44e4d9b1af3a7cf3bed0009686737c7f8a279596

docs: fix incorrect link to prettier package (#2404)

view details

Chris Brody

commit sha b62331ad02dcff3236e18f10eb92d59e7371d4c3

fix(typescript-estree): ts.NamedTupleMember workaround for <TS4.0 (#2405)

view details

Alexander T

commit sha 3764248084455409f085c5bc4706079405cef618

fix(eslint-plugin): [explicit-module-boundary-types] ignore abstract setters (#2410)

view details

phiresky

commit sha fde89d4d392ef35cac2bc09f2774bfe397b20100

feat(eslint-plugin): add `no-implicit-any-catch` rule (#2202) Co-authored-by: Glen <glen.84@gmail.com> Co-authored-by: Brad Zacher <brad.zacher@gmail.com>

view details

Brad Zacher

commit sha fd2070c4c669885f003b8887890aedac0c03139f

docs(eslint-plugin): [no-non-null-asserted-optional-chain] correct docs for 3.9 functionality Closes #2412

view details

Brad Zacher

commit sha d468cfe10e49e96d59f2ea4bc50cc0db0f03541f

docs(eslint-plugin): [no-non-null-asserted-optional-chain] fix formatting

view details

Sergey Bakulin

commit sha a53f8c6ff37aa47b3fc1b729e359d81ea079ff75

fix(eslint-plugin): [explicit-module-boundary-types] ignore all bodyless setters (#2413)

view details

Brad Zacher

commit sha e6be62128b3a98541fe590512892c4b501914e46

feat(typescript-estree): update allowed TS version range (#2419) TS v4.0 is released, we can now bump our range to allow it, as we have full support for it.

view details

Saraswathy Renuga

commit sha 32fe2bb4fe5524355eef4f3a9bd85c824e9d7f46

fix(eslint-plugin): [no-unnecessary-condition] better handling for unary negation (#2382)

view details

James Henry

commit sha 50f9c4afcb08f65a5c6410e8a08f90df6f266cac

chore: publish v3.10.0

view details

Brad Zacher

commit sha 797a13301c3f24683e2492c1dd837fdcf6977d51

chore: update ISSUE_TEMPLATE.md

view details

Brad Zacher

commit sha d1f08879338c825a1a20406fe47c051a287d6519

fix(eslint-plugin): [no-unnecessary-condition] correct regression with unary negations (#2422) Fixes #2421

view details

James Henry

commit sha 43b1201a73687e29f19a16b0b26f68569f3c7a2e

chore: publish v3.10.1

view details

Felipe Santos

commit sha a10d6714731561ba475530d81ce9befba6453fb0

docs: adjust prettier snippet (#2427)

view details

Brad Zacher

commit sha 3854d6cca0b91f6a991f7b11a9740b4a578b01e1

chore: setup automatic RC release for v4 branch

view details

Brad Zacher

commit sha e9d2ab638b6767700b52797e74b814ea059beaae

feat: support ESTree optional chaining representation (#2308)

view details

Brad Zacher

commit sha 3be125d9bdbee1984ac6037874edf619213bd3d0

feat: consume new scope analysis package (#2039)

view details

Brad Zacher

commit sha c70f54fd3a46a12060ae3aec0faae872c431dd88

fix(eslint-plugin): [no-unused-vars] handle TSCallSignature (#2336)

view details

push time in a month

push eventremcohaszing/eslint-plugin-eslint-comments

Remco Haszing

commit sha bb8d777c94852f3066f283f1a362a78cf43ffccc

Make comment-style work on older NodeJS versions

view details

push time in a month

push eventremcohaszing/DefinitelyTyped

Remco Haszing

commit sha 207509b1b789dd7b10f6738c3487ecabbd11b879

Fix tests

view details

push time in a month

Pull request review commentDefinitelyTyped/DefinitelyTyped

Update Koa-webpack to 6.0 and add missing types for koa state

 // TypeScript Version: 2.3  import Koa = require('koa');+import MemoryFileSystem = require('memory-fs'); import webpack = require('webpack'); import webpackDevMiddleware = require('webpack-dev-middleware'); import webpackHotClient = require('webpack-hot-client'); +declare module 'koa' {+    interface DefaultState {

I agree Koa types are a bit odd.

I changed the type from MemoryFileSystem to webpackDevMiddleware.Options['fs']

remcohaszing

comment created time in a month

PullRequestReviewEvent

push eventremcohaszing/DefinitelyTyped

Remco Haszing

commit sha 85f3edc59ace0012f9dc7d2e7494cc92e1688a82

Delegate ctx.state.fs from webpack-dev-middleware

view details

push time in a month

push eventremcohaszing/gatsby-remark-mermaid

Remco Haszing

commit sha 703f421be3dad08302149eed0c9e0eb2066865d2

Bump dependencies The puppeteer peer dependency was changed to `*`, because there have been a lot of major releases that aren’t very breaking.

view details

Remco Haszing

commit sha caaf361d87aa7d5e4ee4970a60621ae881a43e14

2.1.0

view details

push time in a month

created tagremcohaszing/gatsby-remark-mermaid

tagv2.1.0

created time in a month

push eventremcohaszing/babel-plugin-transform-react-class-to-function

Remco Haszing

commit sha 984ccad897c2d0c91bd8ccc61a854a0b8ff86b1f

Bump dependencies

view details

Remco Haszing

commit sha cda8d16fa250d6c43053bff10a81a1f50cfb1d58

Update dependencies The ESLint configuration is now based on `eslint-config-remcohaszing`.

view details

push time in a month

push eventremcohaszing/eslint-plugin-eslint-comments

Remco Haszing

commit sha 4ab62e99f9f47ed39db0428a296b45f7e1161687

Add new rule comment-style This rule enforces `eslint-disable-line` and `eslint-disable-next-line` comments to be line comments instead of block comments.

view details

push time in a month

PR opened axios/axios

Fixing node types

The ProgressEvent type comes from the DOM lib. This is typically unwanted when using axios in a NodeJS environment.

Fixes #3219

+2 -2

0 comment

1 changed file

pr created time in a month

create barnchremcohaszing/axios

branch : fix-node-types

created branch time in a month

push eventremcohaszing/axios

Xianming Zhong

commit sha a9010e4525c89cd84ef38f72c60fd84dc09c9352

Add GitHub actions to close invalid issues (#3022) * add close actions * fix with checkout * update issue templates * add reminder * update close message

view details

Xianming Zhong

commit sha 3dbf6a1b6a80c55a2f3547d7350cb4eb5de1d23b

Add GitHub actions to close stale issues/prs (#3029) * prepare stale actions * update messages * Add exempt labels and lighten up comments Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Jay

commit sha 1768c23da048824123ad4081541641f5c91c1b59

Update close-issues.yml (#3031) * Update close-issues.yml Update close message to read better 😄 * Fix use of quotations Use single quotes as per other .yml files * Remove user name form message

view details

Jay

commit sha 5b08fc4ac7ecc896efa37952645ea578a3609fc2

Add days and change name to work (#3035)

view details

Xianming Zhong

commit sha c70fab9d564d78163738d0957ae8ce1a2834e09f

Fix stale bot config (#3049) * fix stale bot config * fix multiple lines

view details

Frostack

commit sha bed67834526c837ca18eb5674f8c9dda09e18e17

add table of content (preview) (#3050) * add toc (preview) * remove toc in toc Signed-off-by: Moni <usmoni@gmail.com> * fix sublinks * fix indentation * remove redundant table links * update caps and indent * remove axios Co-authored-by: Moni <usmoni@gmail.com> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Kamil Posiadała

commit sha c4300a88cf994b9c4b88b065806edb98705a2c5d

Adding support for URLSearchParams in node (#1900) * Adding support for URLSearchParams in node * Remove un-needed code * Update utils.js * Make changes as suggested Co-authored-by: Kamil Posiadala <kamil.posiadala@codecentric.de> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Cr

commit sha 16aa2ce7fa42e7c46407b78966b7521d8e588a72

Fixing response with utf-8 BOM can not parse to json (#2419) * fix: remove byte order marker (UTF-8 BOM) when transform response * fix: remove BOM only utf-8 * test: utf-8 BOM * fix: incorrect param name Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Emily Morehouse

commit sha fe147fbd3b19393e86d25441bdce099aaef90cb1

Updating changlog for 0.20.0 beta release

view details

Emily Morehouse

commit sha ffea03453f77a8176c51554d5f6c3c6829294649

Releasing 0.20.0-0

view details

Emily Morehouse

commit sha cd27741ff6c99704e22c66ee7ffde26b57d87d5a

Updating changelog for 0.20.0 release

view details

Emily Morehouse

commit sha 0d8765562401910c1c509f6739a3bc558721e123

Releasing 0.20.0

view details

Remco Haszing

commit sha 19a7591c2dc99a21f13965d64af8aa909b594b3c

Change headers type to string record This correctly reflects the type in a more type safe manner.

view details

push time in a month

created tagremcohaszing/axios

tagv0.20.0

Promise based HTTP client for the browser and node.js

created time in a month

created tagremcohaszing/axios

tagv0.20.0-0

Promise based HTTP client for the browser and node.js

created time in a month

push eventremcohaszing/axios

Gustavo López

commit sha 6642ca9aa1efae47b1a9d3ce3adc98416318661c

Add independent `maxBodyLength` option (#2781) * Add independent option to set the maximum size of the request body * Remove maxBodyLength check * Update README * Assert for error code and message

view details

Spencer von der Ohe

commit sha 42eb9dfabc85ed029462da1c503f8b414b08ffd0

Adding option to disable automatic decompression (#2661) * Adding ability to disable auto decompression * Updating decompress documentation in README * Fixing test\unit\adapters\http.js lint errors * Adding test for disabling auto decompression * Removing changes that fixed lint errors in tests * Removing formating change to unit test Co-authored-by: Xianming Zhong <chinesedfan@qq.com>

view details

grumblerchester

commit sha c98ce7d464488dd59a6987cfaf08a4c7b31b96a2

Adding tests for method `options` type definitions (#1996) Update tests. Co-authored-by: Xianming Zhong <chinesedfan@qq.com>

view details

Motonori Iwata

commit sha 5189afff38dc0689ac0c1b1bfa51626bb8541709

Allow PURGE method in typings (#2191) Co-authored-by: Xianming Zhong <chinesedfan@qq.com>

view details

Alan Wang

commit sha 885ada6d9b87801a57fe1d19f57304c315703079

Fixing getting local files (file://) failed (#2470) * fix issue #2416, #2396 * fix Eslint warn * Modify judgment conditions * add unit test * update unit test * update unit test

view details

Benny Neugebauer

commit sha c120f44d3d29c8e822a92e1d6879b8b77be6b9dc

Fixing 'progressEvent' type (#2851) * Fix 'progressEvent' type * Update axios.ts

view details

Remco Haszing

commit sha 5e0fb5fc998d7f9f5a897363977b42f4fa047238

Updating documentation for usage form-data (#2805) Closes #2049 Co-authored-by: Xianming Zhong <chinesedfan@qq.com>

view details

hexaez

commit sha 16b5718954d88fbefe17f0b91101d742b63209c7

Update README.md about validateStatus (#2912) Rewrote the comment from "Reject only if the status code is greater than or equal to 500" to "Resolve only if the status code is less than 500"

view details

Jay

commit sha fd57956a7eadf13fd8006bd53e5065590e9812c4

Documentation update to clear up ambiguity in code examples (#2928) * Made a adjustment to the documenation to clear up any ambiguity around the use of "fs". This should help clear up that the code examples with "fs" cannot be used on the client side. Co-authored-by: Jay <jason.saayman@basebone.com>

view details

Samina Fu

commit sha 021e741aa1fbc24e497519a826e033e006737716

Add CDNJS version badge in README.md (#878) This badge will show the version on CDNJS! Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Ryan Bown

commit sha 1cdf9e4039ede6dd5e033112f3ff6bbaffb66970

Fixing Cookie Helper with Asyc Components (#1105) (#1107) Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

David Ko

commit sha 920510b3a6fecdeb2ba2eb472b0de77ec3cbdd06

Bug/allow header to contain http verb keys #1252 (#1258) * Failing test for #1252 * Only delete header keys that match an HTTP verb if the value is a non-string Co-authored-by: David Ko <david.ko@pvtmethod.com> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Jay

commit sha cbda78552b48bed68a014b1b1bfdf8bd6cd79ec3

Revert "Bug/allow header to contain http verb keys #1252 (#1258)" (#2977) This reverts commit 920510b3a6fecdeb2ba2eb472b0de77ec3cbdd06.

view details

huangzuizui

commit sha a98755c00a851765074e4ed866151232e03f931f

fix 'Network Error' in react native android (#1487) There is a bug in react native Android platform when using get method. It will trigger a 'Network Error' when passing the requestData which is an empty string to request.send function. So if the requestData is an empty string we can set it to null as well to fix the bug. Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Petr Mares

commit sha 5effc0827e2134744d27529cb36970994768263b

Fixing password encoding with special characters in basic authentication (#1492) * Fixing password encoding with special characters in basic authentication * Adding test to check if password with non-Latin1 characters pass Co-authored-by: petr.mares <petr.mares@linecorp.com> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

David

commit sha 8a8c534a609cefb10824dec2f6a4b3ca1aa99171

Fixing special char encoding (#1671) * removing @ character from replacement list since it is a reserved character * Updating buildURL test to not include the @ character * Removing console logs Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Zac Delventhal

commit sha a9a3b5e22b1e1d577d52ec636be6f690ebd2d655

Fixing default transformRequest with buffer pools (#1511) * Fixing default transformRequest of TypedArrays with buffer pools A buffer pool is a large ArrayBuffer of a preset size used with a TypedArray such as Uint8Array. This can speed up performance when constructing TypedArrays of unknown sizes, and is a technique used by Node with their Buffers, and by libraries like dcodeIO/protobuf.js. Because the ArrayBuffer of such a TypedArray is much longer than the array itself, using `.buffer` to transform the array before POSTing results in sending a request with many extraneous empty bytes, which is wastefule and may result in unexpected behavior. Using `.slice()` before grabbing the ArrayBuffer fixes the problem by creating a new TypedArray with a buffer of the expected length. Signed-off-by: Zac Delventhal <delventhalz@gmail.com> * Adding test for using default transformRequest with buffer pools Adds a new test to the default transformRequest, running it on a Uint8Array with a byte length of 16, but a much larger ArrayBuffer with a byte length of 256. The transformed array should not include any extra bytes, and so must have a byte length of just 16. Signed-off-by: Zac Delventhal <delventhalz@gmail.com> Co-authored-by: Zac Delventhal <zac@bitwise.io> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Michał Zarach

commit sha 029c36e193c779e516dbb6609e924ad2727c962e

Include swagger-taxos-codegen in ECOSYSTEM.md (#2162) Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

Taemin Shin

commit sha b03f16159eac889baba067ff1e53e8701c86728e

Fixing an issue that type 'null' is not assignable to validateStatus (#2773) Co-authored-by: Xianming Zhong <chinesedfan@qq.com> Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

marcinx

commit sha 6d36dbe7b733563b3569a2ff6e7e05299c6222ef

Update README.md (#2887) Small change to the data attribute doc of the config. A request body can also be set for DELETE methods but this wasn't mentioned in the documentation (it only mentioned POST, PUT and PATCH). Took my some 10-20 minutes until I realized that I don't need to manipulate the request body with transformRequest in the case of DELETE. Co-authored-by: Jay <jasonsaayman@gmail.com>

view details

push time in a month

delete branch remcohaszing/axios

delete branch : node-form-data

delete time in a month

delete branch remcohaszing/axios

delete branch : document-form-data

delete time in a month

push eventremcohaszing/axios-test-instance

Remco Haszing

commit sha 03c2a7301364d3e48cec9dda88e96f962be19675

Revert "3.2.0" This reverts commit 2443156f4cba0b698f59124060688f7f87bef95e.

view details

push time in a month

created tagremcohaszing/axios-test-instance

tagv3.2.0

Test NodeJS backends using Axios

created time in a month

delete tag remcohaszing/axios-test-instance

delete tag : v3.2.0

delete time in a month

release remcohaszing/axios-test-instance

v3.2.0

released time in a month

push eventremcohaszing/axios-test-instance

Remco Haszing

commit sha b327f950a60ab659815d63d29215ac8b07c8908a

Update dependencies Axios has been updated to 0.20. Internally all dev dependencies have been updated and `eslint-config-remcohaszing` is used.

view details

Remco Haszing

commit sha 2443156f4cba0b698f59124060688f7f87bef95e

3.2.0

view details

push time in a month

created tagremcohaszing/axios-test-instance

tagv3.2.0

Test NodeJS backends using Axios

created time in a month

issue openedmicrosoft/vscode-eslint

Limit underline for large reported nodes

Some ESLint rules highlight large nodes. This causes large code blocks to get reported in the editor. This is a bad UX, as this makes it hard to see other issues in the file.

In a discussion in jest-community/eslint-plugin-jest#539, jest-community/eslint-plugin-jest#641, and jest-community/eslint-plugin-jest#654, a collaborator stated this should be solved by the editor plugins, not the plugins.

The issue isn’t limited to one rule. For example filenames/match-regex reports the Program node.

I can’t think of a proper solution myself. Perhaps the number of lines highlighted by a single ESLint report can be limited.

created time in a month

PR opened mysticatea/eslint-plugin-eslint-comments

Add new rule comment-style

This rule enforces eslint-disable-line and eslint-disable-next-line comments to be line comments instead of block comments.

+143 -1

0 comment

5 changed files

pr created time in a month

create barnchremcohaszing/eslint-plugin-eslint-comments

branch : comment-style

created branch time in a month

pull request commentjest-community/eslint-plugin-jest

refactor(expect-expect): report test callee instead of call expression

I agree technically the function callback, not the identifier. However, I disagree it’s up to the editor how the ESLint results are highlighted.

ESLint rules report a text range, or a node which has a text range. I think it’s fair to say the editor should underline the text range with a red squirly line.

I believe it’s a bad UX if such a large piece of the code is underlined. Reporting identifier may not be the best solution. What about reporting the last character of the callback.

   it('should do something', () => {
     const result = something();
   });
// ^-- Report this character

   it('should do something', () =>
     something()
     //        ^-- Report this character, because the test has no closing body bracket
   );

This could be interpreted as: I got to the end of your test case, but still didn’t find an expectation.

Alternatively all code between the last statement and the closing bracket of the test could be reported

   it('should do something', () => {
     const result = something();
   });
// ^-- Report this character and all whitespace before it.

   it('should do something', () =>
     something()
   );
// ^-- Report all whitespace before this character.
remcohaszing

comment created time in a month

PR opened jest-community/eslint-plugin-jest

refactor(expect-expect): report test callee instead of call expression

When one starts writing a test, they often start with something like the following:

image

This triggers the jest/expect-expect rule for a good reason, but it’s annoying, confusing even, when the entire test block has a red underline until an expect statement is added.

This changes the rule to report the callee, only. This limits the scope of the reported code, so the red lines that do appear while typing are more meaningful, i.e. result is unused:

image

+12 -12

0 comment

2 changed files

pr created time in a month

push eventremcohaszing/preact

Remco Haszing

commit sha bab8f2ee8af9dd96b3094e3e5e3f9aa9a2fce470

Fix IntrinsicElements augmentation

view details

push time in a month

created tagremcohaszing/eslint-config

tag1.2.1

A strict ESLint configuration

created time in a month

push eventremcohaszing/eslint-config

Remco Haszing

commit sha 459c4ac36f5b4dad177d3345ffca42939f551c5a

Fix Preact error handling

view details

Remco Haszing

commit sha a514656eacf773a905aedd4cb86aed3c049997a0

Disable require-atomic-updates This doesn’t play nice with Koa.

view details

Remco Haszing

commit sha e2ccc11479153aa03797140174d1053f398ab086

Disable unicorn/prefer-replace-all `String.prototype.replaceAll` doesn’t exist yet in most environments.

view details

Remco Haszing

commit sha 88af5438a73e456ce14999b0cb76483fbf126515

Enforce balanced spacing in block comments

view details

Remco Haszing

commit sha ab47bb175d1cde70d3d3f68002d1a4d27b068a64

Bump dependencies TypeScript has been held back

view details

Remco Haszing

commit sha 5c1c26f8f835baf33be21bfd46099c6e9633dbbf

Allow arguments on toString() calls

view details

Remco Haszing

commit sha 8ca55af637b7be38932216b7ca8647ca96ec44cf

Make all sorting case insensitive

view details

Remco Haszing

commit sha 85f9b0141b9a1944bb9dd9da913cb6cc3a275fd5

Disable @typescript-eslint/no-type-alias

view details

Remco Haszing

commit sha 730b9e86e585db4fea3e72bb9d5b50cf345d1422

Disable @typescript-eslint/no-dynamic-delete

view details

Remco Haszing

commit sha e933adc0a63127431310a117955a36aea581f635

Disable new-cap for TypeScript PascalCase is allowed for decorators as well.

view details

Remco Haszing

commit sha 65f93c9f7d2269f198df1d39e92f684f2d510c37

Disable import rules that conflict with TypeScript

view details

Remco Haszing

commit sha dc2dc475f03ef9a99ff84458b33e8b93bb290b9b

Disable rule @typescript-eslint/strict-boolean-expressions

view details

Remco Haszing

commit sha 6cb1d5f9b6aa90c74bc1cbf46f9df4fa3f6826c5

Enable rule @typescript-eslint/no-implicit-any-catch

view details

Remco Haszing

commit sha 5b5e28372f0da4459be5d1ba647650ce6000cbce

Add new web preset

view details

Remco Haszing

commit sha ae50ad3ea3efd65f44d33989fa47b6da83121a96

Bump version in package.json

view details

Remco Haszing

commit sha 429bf6d9861f7ff4ac49c20d0af107239553186c

Disable node/no-unpublished-import in dev config

view details

Remco Haszing

commit sha 7b027f9c19cb6d55068272318686c80d8a9841c4

Allow unused vars in markdown examples

view details

Remco Haszing

commit sha 533b2d70b2daa4729ac33fc3be8d671d6ea32c25

Release version 1.2.1

view details

push time in a month

PR opened preactjs/preact

Infer JSX.IntrinsicElements from DOM lib

HTML elements are inferred from the HTMLElementTagNameMap in dom, and the SVG elements are inferred from SVGElementTagNameMap.

The HTMLMarqueeElement exists in dom and is no longer used, so it has been removed.

There’s more to the cleanup than I initially anticipated, so I decided to do this gradually.

Refs #2706

+8 -178

0 comment

1 changed file

pr created time in a month

create barnchremcohaszing/preact

branch : infer-element-tag-names

created branch time in a month

pull request commenteslint/eslint

Update: Add templateString option in no-implicit-coercion (fixes #12866)

This also resolves a race condition in the fixers of prefer-template and no-implicit-coercion.

Input

'' + foo;

Output when autofixed by prefer-template:

`${foo}`;

Output by no-implicit-coercion

String(foo);

This option will still trigger no-implicit-coercion after prefer-template has run its autofixer, meaning there is only one correct way to write this string conversion if both rules are enabled.

remcohaszing

comment created time in a month

Pull request review commentDefinitelyTyped/DefinitelyTyped

Update Koa-webpack to 6.0 and add missing types for koa state

 // TypeScript Version: 2.3  import Koa = require('koa');+import MemoryFileSystem = require('memory-fs'); import webpack = require('webpack'); import webpackDevMiddleware = require('webpack-dev-middleware'); import webpackHotClient = require('webpack-hot-client'); +declare module 'koa' {+    interface DefaultState {

This is how DefaultState is supposed to be used according to the tsdoc (link). The same goes for DefaultContext.

There are multiple packages on DefinitelyTyped that augment these types this way.

remcohaszing

comment created time in a month

PullRequestReviewEvent

release remcohaszing/eslint-config

1.2.0

released time in a month

created tagremcohaszing/eslint-config

tag1.2.0

A strict ESLint configuration

created time in a month

PR opened yannickcr/eslint-plugin-react

[Fix] `jsx-uses-react`: mark fragment variables as used

This allows to use the following syntax:

import { createElement, Fragment } from 'react';

function Component {
  return <></>;
}

Or more common in Preact:

import { Fragment, h } from 'preact';

function Component {
  return <></>;
}

The react.fragment setting already existed for other rules, but it was undocumented.

+11 -1

0 comment

3 changed files

pr created time in a month

created tagremcohaszing/eslint-plugin-react

tagv7.20.6

React specific linting rules for ESLint

created time in a month

create barnchremcohaszing/eslint-plugin-react

branch : jsx-uses-react-fragment

created branch time in a month

PR opened DefinitelyTyped/DefinitelyTyped

Update Koa-webpack to 6.0 and add missing types for koa state

This adds types for the injected Koa state propertis fs and state.

Since koa-webpack recently released 6.0 without really breaking changes, the version was updated as well.

  • [x] Use a meaningful title for the pull request. Include the name of the package modified.
  • [x] Test the change in your own code. (Compile and run.)
  • [x] Add or edit tests to reflect the change. (Run with npm test.)
  • [x] Follow the advice from the readme.
  • [x] Avoid common mistakes.
  • [x] Run npm run lint package-name (or tsc if no tslint.json is present).
  • [x] Provide a URL to documentation or source code which provides context for the suggested changes: https://github.com/shellscape/koa-webpack/compare/v6.0.0..v5.3.0
  • [x] If this PR brings the type definitions up to date with a new version of the JS library, update the version number in the header.
  • [x] Include tests for your changes
  • [x] If you are making substantial changes, consider adding a tslint.json containing { "extends": "dtslint/dt.json" }. If for reason the any rule need to be disabled, disable it for that line using // tslint:disable-next-line [ruleName] and not for whole package so that the need for disabling can be reviewed.
+39 -20

0 comment

2 changed files

pr created time in a month

create barnchremcohaszing/DefinitelyTyped

branch : koa-webpack-koa-context

created branch time in a month

pull request commentDefinitelyTyped/DefinitelyTyped

Enhance langmap types

Ready to merge

remcohaszing

comment created time in a month

pull request commentmicrosoft/vscode

Mark .desktop files as ini

I think this is an issue with the ini language definition, not .desktop files. Inline comments shouldn’t be allowed.

E.g. from https://editorconfig.org/ (also in the extensions list):

EditorConfig files use an INI format that is compatible with the format used by Python ConfigParser Library, […truncated…] and octothorpes (#) or semicolons (;) are used for comments. Comments should go on their own lines.

>>> import configparser
>>> parser = configparser.ConfigParser()
>>> parser.read_string("""
... [foo]
... bar = baz; fooz
... """)
>>> parser.get('foo', 'bar')
'baz; fooz'
>>>

Another source: https://en.wikipedia.org/wiki/INI_file#Comments

I don’t think there’s an official standard for the ini format.

remcohaszing

comment created time in a month

issue openedfacebook/jest

Return cleanup functions from beforeAll and beforeEach

🚀 Feature Proposal

It would be a nice addition if the beforeAll() and beforeEach() function could return cleanup functions. This is based on the cleanup function of React.useEffect().

Because one setup may depend on another, the cleanup functions should run in the reverse order of their definition after the afterAll() and afterEach() blocks respectively. I.e. the following test:

afterAll(() => {
  console.log(1);
});

beforeAll(() => {
  console.log(2);

  return () => {
    console.log(3);
  };
});

afterAll(() => {
  console.log(4);
});

beforeAll(() => {
  console.log(5);

  return () => {
    console.log(6);
  };
});

afterAll(() => {
  console.log(7);
});

it('', () => {
  console.log('test');
});

will log:

2
5
test
1
4
7
6
3

Motivation

Currently one needs to store the variables on a higher scope, so the cleanup can be done in a afterAll() or afterEach() block. This works fine, but it’s more work. One needs to declare the variables and possibly explicitly add type definitions. Also returning such cleanup functions keeps related setup and cleanup close together.

Example

Currently:

import { Sequelize } from 'sequelize-typescript';

import { User } from '../models';
import { setupDB } from '../utils';

let db: Sequelize;

beforeAll(async () => {
  db = await setupDB();
});

afterAll(async () =>
  await db.close();
});

it('should create a user', async () => {
  await User.create({ name: 'Me' });
});

With returned cleanup functions.

import { User } from '../models';
import { setupDB } from '../utils';

beforeAll(async () => {
  const db = await setupDB();

  return () => db.close();
});

it('should create a user', async () => {
  await User.create({ name: 'Me' });
});

Variables can still be assigned for use in other setup blocks or tests

import { Sequelize } from 'sequelize-typescript';

import { User } from '../models';
import { setupDB } from '../utils';

let db: Sequelize

beforeAll(async () => {
  db = await setupDB();

  return () => db.close();
});

afterEach(async () => {
  await db.truncate()
});

it('should create a user', async () => {
  await User.create({ name: 'Me' });
});

Pitch

This changes the behaviour of beforeAll() and beforeEach().

created time in a month

create barnchremcohaszing/vscode

branch : ini-desktop-files

created branch time in a month

PR opened microsoft/vscode

Mark .desktop files as ini

Linux desktop entries are ini files using the .desktop extension.

+1 -1

0 comment

1 changed file

pr created time in a month

PR opened DefinitelyTyped/DefinitelyTyped

Enhance langmap types
  • Types are exported in the index, as types.d.ts doesn’t map to an existing JavaScript file.

  • esModuleInterop was removed from tsconfig.json for correctness.

  • Tests were changed not to use esModuleInterop and to use $ExpectType annotations.

  • [x] Use a meaningful title for the pull request. Include the name of the package modified.

  • [x] Test the change in your own code. (Compile and run.)

  • [x] Add or edit tests to reflect the change. (Run with npm test.)

  • [x] Follow the advice from the readme.

  • [x] Avoid common mistakes.

  • [x] Run npm run lint package-name (or tsc if no tslint.json is present).

  • [x] Provide a URL to documentation or source code which provides context for the suggested changes: https://github.com/mozilla/language-mapping-list

  • [x] If this PR brings the type definitions up to date with a new version of the JS library, update the version number in the header.

  • [x] Include tests for your changes

  • [x] If you are making substantial changes, consider adding a tslint.json containing { "extends": "dtslint/dt.json" }. If for reason the any rule need to be disabled, disable it for that line using // tslint:disable-next-line [ruleName] and not for whole package so that the need for disabling can be reviewed.

+21 -21

0 comment

4 changed files

pr created time in a month

create barnchremcohaszing/DefinitelyTyped

branch : enhance-langmap-types

created branch time in a month

pull request commentgajus/eslint-plugin-jsdoc

fix(`no-bad-blocks`): allow TypeScript directive comments

I made it customizeable as per option in 2.i. I didn’t check for settings.jsdoc.mode, because I think it might be confusing the mode changes the defaults for this rule, and I don’t think anyone would use TS directive comments for anything other than TypeScript.

remcohaszing

comment created time in a month

push eventremcohaszing/eslint-plugin-jsdoc

Remco Haszing

commit sha c2be7fe0955ab72591013109aa9f7151bbdbb2f4

feat(`no-bad-blocks`): make ignored tags customizable

view details

push time in a month

pull request commentgajus/eslint-plugin-jsdoc

fix(`no-bad-blocks`): allow TypeScript directive comments

Sure, I’ll get to it later today. I’ll add a property ignored, which is an array that accepts ignored tag names.

What should the behaviour be for defaults?

  1. Don’t add any defaults
  2. Default to TypeScript comments
    1. Specifying ignore overrides the defaults.
    2. Specifying ignore appends the defaults.
remcohaszing

comment created time in a month

PR opened gajus/eslint-plugin-jsdoc

fix(`no-bad-blocks`): allow TypeScript directive comments

This allows TypeScript directive comments in block comments.

Although these comments are mostly written using line comments, block comments must be used in some situations, e.g. when inside JSX tags.

+27 -1

0 comment

2 changed files

pr created time in a month

create barnchremcohaszing/eslint-plugin-jsdoc

branch : no-bad-blocks-ts-comments

created branch time in a month

PR opened YousefED/typescript-json-schema

Update all dependencies

Most notably this upgrades to TypeScript 4.

One expression has been removed from typescript-json-schema.ts. This doesn’t break any tests, so it’s probably fine.

Please:

  • [x] Make your pull request atomic, fixing one issue at a time unless there are many relevant issues that cannot be decoupled.
  • [x] Provide a test case & update the documentation in the Readme.md
+387 -289

0 comment

3 changed files

pr created time in a month

created tagremcohaszing/typescript-json-schema

tagv0.42.1

Generate json-schema from your Typescript sources

created time in a month

create barnchremcohaszing/typescript-json-schema

branch : typescript-4

created branch time in a month

push eventremcohaszing/typescript-eslint

Remco Haszing

commit sha e8e8dbe55ecf695dd366a5b6d2ed44f9611b21bb

test(eslint-plugin): [consistent-indexed-object-style: add missing tests

view details

push time in a month

issue commentpreactjs/preact

Remove irrelevant types from JSX namespace

I learnt some things about TypeScript and JSX while writing mini-jsx.

I noticed in props.js a similar way is used to assign props to DOM nodes. This means the existing builtin TypeScript types from HTMLElementTagNameMap and SVGElementTagNameMap could be used to avoid the need to maintain most of the current HTMLAttributes interface in Preact.

This will also improve typings, i.e. an input has a checked property in the TypeScript DOM types, but not a div element. In Preact there’s currently no distinction.

Instead of introducing the deprecation policy I described in the original comment, I’d prefer to take the liberty to make some breaking changes.

Is there an ETA for Preact 11? I think it’s better to make these changes for a major release.

remcohaszing

comment created time in a month

issue commentmicrosoft/TSJS-lib-generator

Missing iterator types for HTMLCollectionBase and StyleSheetList

Apparently this requires the dom.iterable lib in addition to dom. I think the issue can be closed.

remcohaszing

comment created time in a month

issue closedmicrosoft/TSJS-lib-generator

Missing iterator types for HTMLCollectionBase and StyleSheetList

The following types are missing from the dom lib:

interface HTMLCollectionBase {
  [Symbol.iterator]: () => Iterator<Element>;
}

interface StyleSheetList {
  [Symbol.iterator]: () => Iterator<CSSStyleSheet>;
}

This makes the following code work:

const nodes = [...document.body.children];
const currenStyleSheets = [...document.styleSheets];

There may be more similar cases I’m not aware of.

closed time in a month

remcohaszing
more