-
Notifications
You must be signed in to change notification settings - Fork 205
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
Call for maintainers #346
Comments
Hi! I might help maintaining the repo "passively" if you want. I could monitor PRs and help them get merged in, potentially also providing emergency fixes in case something gets really broke. I don't have time to maintain issues though. |
Thanks for your kind words, @tleunen. I'm also looking at this project much less now, especially since it just works ™️ for me. The biggest issues right now are two things that, frankly, I don't want to get into:
There are some problems that are inherent to the way caching works in most places, and the plugin can't deal with them as it is built right now: eg. renaming In short: I might be migrating away from the plugin too, it was nice while it lasted, but the time to move on approaches. |
@fatfisz Just found this plugin, sad. I'm working on a package that doesn't get webpacked (only parsed via babel). What're you migrating away to if I may ask? |
If you're using only Babel, then this plugin is still one of the best things you can get. But otherwise most bundling/testing tools already provide their own means of resolving paths that don't suffer from the cache problem. With Rollup it's possible viarollup-plugin-node-resolve. Parcel also allows configuring path resolver. I won't be migrating to some other plugin - I'll just stick to config in Webpack & Jest. It's just a shame that Node.js' path resolution algorithm doesn't handle something like |
Lots of ../../.. in the source and in the docs made things pretty cumbersome. Now, there's an alias `@` which points to the root directory. I went with `@` instead of a name like `root` just to avoid any confusion thinking there's a real npm module with that name. Also, this could have been done with a single babel plugin, but there seems to be some concern that jest or webpack caching may break, so instead I went with tool-specific plugins/settings for webpack/jest/rollup. tleunen/babel-plugin-module-resolver#346
If you're wanting to use something like this in jest, the following config options may be useful:
I also did a bit of deep dive/exploration in #375 to try and figure out why jest-resolve wasn't being hooked, so that ticket shows how you could implement a custom resolver entirely in jest. |
@fatfisz I just noticed your comment and think I may be experiencing the same issue:
I created the following settings: "plugins": [
[
"module-resolver",
{
"alias": {
"~": "./src",
"#serviceFixtures": "./src/services/__fixtures__"
}
}
]
] This allows me to import everything based on the root like so: Are you saying what I am trying to do is not possible? Is there a workaround? |
Hey there,
As you may have noticed, I'm way less active in this project than I used to be in its early days. The main reason to that is because I'm not an active user of the plugin anymore so finding the time and energy to contribute to it is harder.
I would like to let people contribute more and ideally hand over the project to someone else which will take care of it and keep maintaining it, and hopefully fix the couple issues around Babel 7 and React Native that seem to be present in the recent build.
Please, let me know if you're interested and we can discuss about it, with @fatfisz as well since he was a great contributor.
The text was updated successfully, but these errors were encountered: