Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Outdated handbook page for eslint-config package #14724

Closed
strarsis opened this issue Mar 30, 2019 · 6 comments
Closed

Outdated handbook page for eslint-config package #14724

strarsis opened this issue Mar 30, 2019 · 6 comments
Labels
[Package] ESLint plugin /packages/eslint-plugin [Type] Developer Documentation Documentation for developers

Comments

@strarsis
Copy link
Contributor

strarsis commented Mar 30, 2019

@youknowriad, @aduth, @jasmussen, @ellatrix:

Describe the bug
On Gutenberg handbook page https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-config/ the wrong package name @wordpress/eslint-config is specified.
This package doesn't exist on npm, but the package @wordpress/eslint-plugin exists, which is from Gutenberg and describes itself as being the right one for extending eslint.

Another issue is that this handbook page can't be edited/forked in GitHub,
the GitHub edit link leads to a 404 on GitHub.

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-config/.
  2. Follow the instructions and try to install the package @wordpress/eslint-config (npm or yarn).
    Notice that the package is not found and it is found on the npm registry neither (https://www.npmjs.com/search?q=%40wordpress%2Feslint-config).

Handbook page edit error:

  1. Click the Edit link (with GitHub icon) on the right upper part of page.
    Notice the 404 error on GitHub instead of the forked, editable page.

Expected behavior
Correct package name is stated, which should be eslint-plugin instead of
non-existing @wordpress/eslint-config, not only in the example install command but
also everywhere else (like where eslint is extended with it).

Edit: Extending eslint with the other package @wordpress/eslint-plugin using the config from the package readme (plugin:@wordpress/eslint-plugin/recommended) results in an error, too:
Error: Failed to load plugin @wordpress: Cannot find module 'eslint-plugin-@wordpress'.
There is another handbook page that uses the other package name, but the example config fails:
https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-plugin/

@swissspidy swissspidy changed the title [docs] Wrong package for eslint extend in handbook; non-existing handbook page on GitHub Outdated handbook page for eslint-config package Mar 31, 2019
@swissspidy swissspidy added [Type] Developer Documentation Documentation for developers [Package] ESLint plugin /packages/eslint-plugin labels Mar 31, 2019
@swissspidy
Copy link
Member

Interesting.

https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-plugin/ is the correct link.

The recommended config, "extends": [ "plugin:@wordpress/eslint-plugin/recommended" ] is also correct.

Of course you need to install the package first: npm install @wordpress/eslint-plugin --save-dev

The package was previously @wordpress/eslint-config, but was since changed to @wordpress/eslint-plugin.

So the only issue I see here is that the https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-config/ page should be deleted.

@aduth
Copy link
Member

aduth commented Apr 1, 2019

So the only issue I see here is that the https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-config/ page should be deleted.

Yeah, I believe I'd seen it come up once before in conversation that the current process for mirroring documentation from Gutenberg to WordPress.org does not account for deletion. It's a general issue affecting more than just this one page, though it may be a temporary fix to remove individual items.

@gziolo
Copy link
Member

gziolo commented Apr 2, 2019

@dd32
Copy link
Member

dd32 commented Apr 3, 2019

https://wordpress.org/gutenberg/handbook/designers-developers/developers/packages/packages-eslint-config/

@dd32 can you delete this page which no longer exists on GitHub?

Done.

@swissspidy
Copy link
Member

Thanks!

I guess we can close this issue now :-)

@aduth
Copy link
Member

aduth commented Apr 8, 2019

I'd neglected to follow-up here, but I'd posed the question of deleting outdated documents during last week's #docs meeting (link requires registration):

https://wordpress.slack.com/archives/C02RP4WU5/p1554134966087800

The general consensus seemed to be that it's difficult to justify putting resources toward fixing issues with the current solution, when there's an ongoing effort to migrate this documentation to DevHub as the canonical resource.

If the issue comes up again, I suppose it'll need to similarly be handled in a one-off fashion, with Meta Trac as the designated issue tracker (?).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] ESLint plugin /packages/eslint-plugin [Type] Developer Documentation Documentation for developers
Projects
None yet
Development

No branches or pull requests

5 participants