eslint-plugin-cvsdk-rules 10.1.2 → 10.1.3-oneapp-mt-debug
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.
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prefer-no-lodash-clone-deep.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-no-lodash-clone-deep.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAIvD,eAAO,MAAM,IAAI,+FAwBf,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ESLintUtils } from '@typescript-eslint/utils';
|
|
2
|
+
var createRule = ESLintUtils.RuleCreator(function (name) { return name; });
|
|
3
|
+
export var rule = createRule({
|
|
4
|
+
create: function (context) {
|
|
5
|
+
return {
|
|
6
|
+
"Program:has(ImportDeclaration[source.value='lodash'] > ImportSpecifier[imported.name=cloneDeep]) CallExpression[callee.name=cloneDeep]": function (node) {
|
|
7
|
+
context.report({
|
|
8
|
+
node: node,
|
|
9
|
+
messageId: 'forbiddenCloneDeepUsage',
|
|
10
|
+
});
|
|
11
|
+
},
|
|
12
|
+
};
|
|
13
|
+
},
|
|
14
|
+
name: 'prefer-no-lodash-cloneDeep',
|
|
15
|
+
meta: {
|
|
16
|
+
docs: {
|
|
17
|
+
description: 'Detect usage of Lodash cloneDeep',
|
|
18
|
+
},
|
|
19
|
+
messages: {
|
|
20
|
+
forbiddenCloneDeepUsage: "Prefer using rfdc (@sky-uk-ott/core-video-sdk-js-external-rfdc) over lodash.cloneDeep as it cost a lot in performance",
|
|
21
|
+
},
|
|
22
|
+
schema: [],
|
|
23
|
+
type: 'problem',
|
|
24
|
+
},
|
|
25
|
+
defaultOptions: [],
|
|
26
|
+
});
|
|
27
|
+
//# sourceMappingURL=prefer-no-lodash-clone-deep.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prefer-no-lodash-clone-deep.js","sourceRoot":"","sources":["../../src/rules/prefer-no-lodash-clone-deep.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,IAAM,UAAU,GAAG,WAAW,CAAC,WAAW,CAAC,UAAC,IAAI,IAAK,OAAA,IAAI,EAAJ,CAAI,CAAC,CAAC;AAE3D,MAAM,CAAC,IAAM,IAAI,GAAG,UAAU,CAAC;IAC3B,MAAM,YAAC,OAAO;QACV,OAAO;YACH,wIAAwI,EACpI,UAAC,IAAI;gBACD,OAAO,CAAC,MAAM,CAAC;oBACX,IAAI,MAAA;oBACJ,SAAS,EAAE,yBAAyB;iBACvC,CAAC,CAAC;YACP,CAAC;SACR,CAAC;IACN,CAAC;IACD,IAAI,EAAE,4BAA4B;IAClC,IAAI,EAAE;QACF,IAAI,EAAE;YACF,WAAW,EAAE,kCAAkC;SAClD;QACD,QAAQ,EAAE;YACN,uBAAuB,EAAE,uHAAuH;SACnJ;QACD,MAAM,EAAE,EAAE;QACV,IAAI,EAAE,SAAS;KAClB;IACD,cAAc,EAAE,EAAE;CACrB,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-plugin-cvsdk-rules",
|
|
3
|
-
"version": "10.1.
|
|
3
|
+
"version": "10.1.3-oneapp-mt-debug",
|
|
4
4
|
"main": "./build/index.js",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -22,5 +22,5 @@
|
|
|
22
22
|
"eslint-plugin-eslint-plugin": "6.2.0",
|
|
23
23
|
"typescript": "5.0.2"
|
|
24
24
|
},
|
|
25
|
-
"gitHead": "
|
|
25
|
+
"gitHead": "84e9cc741cdd41bfc5ecd35c7c160f2c1ad35be4"
|
|
26
26
|
}
|