Repository navigation
Packages: Fix all missing or obsolete dependencies in packages - #16969
Conversation
1e34cdb to
000de40
Compare
000de40 to
bf67453
Compare
| 'import/no-extraneous-dependencies': 'error', | ||
| }, | ||
| excludedFiles: [ | ||
| '**/*.@(android|ios|native).js', |
|
I wonder if there's any way we can check the JS files for imports and error if the dependency is not found in the |
So this new ESLint rule ( |
How did you know which dependencies to remove then? |
It was a manual process. I went through |
* Packages: Fix all missing or obsolete dependencies in packages * Enable import/no-extraneous-dependencies rule and fix reported violations * Remove 2 dependencies not used in the project on the global level * Remove unused @wordpress/core-data dependnecy from @wordpress/block-editor
* Packages: Fix all missing or obsolete dependencies in packages * Enable import/no-extraneous-dependencies rule and fix reported violations * Remove 2 dependencies not used in the project on the global level * Remove unused @wordpress/core-data dependnecy from @wordpress/block-editor
Description
I discovered that we have some differences in the list of dependencies for WordPress packages. In particular, I have some issues integrating all recently published npm packages with WordPress core. Related ticket:
https://core.trac.wordpress.org/ticket/47843
How has this been tested?
In general, on Gutenberg side, it all should be transparent as we have build tools which properly generate dependencies consumed by WordPress. In core, we have to do it manually so that might be why it doesn't quite work as necessary.