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

fix(exports): [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" #36

Merged
merged 1 commit into from Aug 3, 2022

Conversation

unicornware
Copy link
Member

Description

Removed deprecated folder mapping "./" from package exports.

The path mapping was not replaced because it isn't needed. All exports are already listed via subpath patterns:

{
  "exports": {
    ".": {
      "types": "./dist/index.d.ts",
      "import": "./dist/index.mjs",
      "require": "./dist/index.cjs"
    },
    "./enums": {
      "types": "./dist/enums/index.d.ts",
      "import": "./dist/enums/index.mjs",
      "require": "./dist/enums/index.cjs"
    },
    "./enums/*": {
      "types": "./dist/enums/*.d.ts",
      "import": "./dist/enums/*.mjs",
      "require": "./dist/enums/*.cjs"
    },
    "./guards": {
      "types": "./dist/guards/index.d.ts",
      "import": "./dist/guards/index.mjs",
      "require": "./dist/guards/index.cjs"
    },
    "./guards/*": {
      "types": "./dist/guards/*.d.ts",
      "import": "./dist/guards/*.mjs",
      "require": "./dist/guards/*.cjs"
    },
    "./package.json": "./package.json",
    "./types": {
      "types": "./dist/types/index.d.ts",
      "import": "./dist/types/index.mjs",
      "require": "./dist/types/index.cjs"
    },
    "./types/*": {
      "types": "./dist/types/*.d.ts",
      "import": "./dist/types/*.mjs",
      "require": "./dist/types/*.cjs"
    }
  }
}

Furthermore, the src directory is now included in distribution files. Source code is included for convenience (source code diving, looking at docs, etc) - not for users to import. Replacing the path mapping would expose src as an import.

Tests

N/A

Additional context

Linked issues

Submission checklist

  • pr naming conventions
  • project was run locally to verify that there are no errors
  • documentation added or updated

@unicornware unicornware added type:fix bug reports and fixes scope:esm es modules labels Aug 3, 2022
@unicornware unicornware self-assigned this Aug 3, 2022
@unicornware unicornware changed the title fix(exports): [DEP0148] Use of deprecated folder mapping "./" fix(exports): [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" Aug 3, 2022
… mapping "./"`

Signed-off-by: Lexus Drumgold <unicornware@flexdevelopment.llc>
@unicornware unicornware force-pushed the feat/fix/29-use-of-deprecated-folder-mapping branch from 460c3ee to 58427c8 Compare August 3, 2022 06:30
Copy link
Contributor

@flexdevelopment flexdevelopment left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm 👍🏾

@unicornware unicornware merged commit e14fc10 into main Aug 3, 2022
@unicornware unicornware added the scope:cjs commonjs label Aug 3, 2022
@unicornware unicornware deleted the feat/fix/29-use-of-deprecated-folder-mapping branch August 3, 2022 06:37
unicornware added a commit that referenced this pull request Aug 3, 2022
… mapping "./"` (#36)

Signed-off-by: Lexus Drumgold <unicornware@flexdevelopment.llc>
unicornware added a commit that referenced this pull request Aug 3, 2022
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent
activity after it was closed. Please open a new issue for related bugs or features. Be
sure to reference this issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
scope:cjs commonjs scope:esm es modules type:fix bug reports and fixes
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

🐛 [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./"
2 participants