Skip to content

Documentation links are broken due to fork versioning #76

@tetarchus

Description

@tetarchus

The documentation URL generator function appears to have been broken by forking and changing versions.

import pkg from '../../package.json'

const repoUrl = 'https://github.com/un-ts/eslint-plugin-import-x'

export const docsUrl = (ruleName: string, commitish = `v${pkg.version}`) =>
  `${repoUrl}/blob/${commitish}/docs/rules/${ruleName}.md`

As the value of commitish is the current version of the package (0.5.0) by default, this generates the URL:
https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/newline-after-import.md.

Due to this being a fork of the original eslint-plugin-import which had a version 0.5.0, there is already a tag v0.5.0 from 9 years ago which does not include the docs folder, and therefore directs you to the incorrect location if using tools such as VSCode's ESLint extension which allows you to click the rule name to be taken to its documentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy