Skip to content

Commit

Permalink
Restrict usage of react imports in favor of @wordpress/element
Browse files Browse the repository at this point in the history
  • Loading branch information
gziolo committed Aug 9, 2019
1 parent 80797c4 commit 7dc61fd
Show file tree
Hide file tree
Showing 4 changed files with 263 additions and 946 deletions.
8 changes: 8 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,14 @@ module.exports = {
files: [ 'packages/**/*.js' ],
rules: {
'import/no-extraneous-dependencies': 'error',
'no-restricted-imports': [ 'error', {
paths: [
{
name: 'react',
message: 'Please use @wordpress/element instead.',
},
],
} ],
},
excludedFiles: [
'**/@(benchmark|test|__tests__)/**/*.js',
Expand Down
Loading

0 comments on commit 7dc61fd

Please sign in to comment.