Skip to content

Commit c15a3f9

Browse files
committed
Testing: Remove lint rule forbidding package path access
Redundant with improved resolver behavior
1 parent bf390b4 commit c15a3f9

File tree

2 files changed

+0
-17
lines changed

2 files changed

+0
-17
lines changed

.eslintrc.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -71,14 +71,6 @@ const restrictedImports = [
7171
];
7272

7373
const restrictedSyntax = [
74-
// NOTE: We can't include the forward slash in our regex or
75-
// we'll get a `SyntaxError` (Invalid regular expression: \ at end of pattern)
76-
// here. That's why we use \\u002F in the regexes below.
77-
{
78-
selector:
79-
'ImportDeclaration[source.value=/^@wordpress\\u002F.+\\u002F/]:not([source.value=/^@wordpress\\u002F.+\\u002Fbuild-types\\u002F/])',
80-
message: 'Path access on WordPress dependencies is not allowed.',
81-
},
8274
{
8375
selector:
8476
'CallExpression[callee.object.name="page"][callee.property.name="waitFor"]',

packages/react-native-editor/.eslintrc.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,6 @@ module.exports = {
2121
rules: {
2222
'no-restricted-syntax': [
2323
'error',
24-
// NOTE: We can't include the forward slash in our regex or
25-
// we'll get a `SyntaxError` (Invalid regular expression: \ at end of pattern)
26-
// here. That's why we use \\u002F in the regexes below.
27-
{
28-
selector:
29-
'ImportDeclaration[source.value=/^@wordpress\\u002F.+\\u002F/]',
30-
message:
31-
'Path access on WordPress dependencies is not allowed.',
32-
},
3324
{
3425
selector:
3526
'CallExpression[callee.name=/^(__|_x|_n|_nx)$/] Literal[value=/\\.{3}/]',

0 commit comments

Comments
 (0)