reduxjs / redux-toolkit

The official, opinionated, batteries-included toolset for efficient Redux development
https://redux-toolkit.js.org
MIT License
10.76k stars 1.18k forks source link

Allow specification for file extension to be used in import statement paths for files created by code generation #4645

Open TheMartianMaker opened 2 months ago

TheMartianMaker commented 2 months ago

Feature Request:

Use Case: For ESM projects, it is often required to include file extensions in import statements. Currently, developers have to manually update the import statements in the generated files to include the necessary file extensions. This feature would automate that process and ensure consistency across the codebase, which is crucial for maintaining proper module resolution in ESM environments.

markerikson commented 2 months ago

Seems reasonable. File a PR?

TheMartianMaker commented 2 months ago

I dont' have the code written for this request. I'm inquiring to see if you guys could add this feature.

markerikson commented 2 months ago

@TheMartianMaker Yeah, I'm saying it's a reasonable request, but it's probably not something we're going to have time to implement ourselves any time soon. Best bet to add it soon is if you can file a PR to make the changes, otherwise it'll probably be a while.

TheMartianMaker commented 1 day ago

@markerikson the PR has been filed :) https://github.com/reduxjs/redux-toolkit/pull/4743