resolve
resolve copied to clipboard
central issue for "default extensions"
This issue encompasses anything that deals with "what the default extensions are/should be".
- #19 points out that
.jsonis not included in the defaults. - #137 points out that
require.extensionsis not used as the defaults - https://github.com/substack/tape/issues/395 is related, but can be addressed with changes in
tape, unrelated to whateverresolvedoes. - (related but addressed: #150, #127, #90, #134)
There's some PRs out that are hoping to change the defaults:
- #138 dynamically reads
require.extensionson every call - #145 replaces the default of
.jswith a hardcoded list of the defaultrequire.extensionsvalue
I'm opening this so I can close the other issues, and so any further discussion can happen here.
Please try to read all of the previous discussions before commenting.
@ljharb well done! I'm subscribed and have my eyes peeled. Seems like as I predicted last year there will be more eyeballs looking in the require.extensions direction.
This is a great synopsis but even myself remember you had made a couple suggestions. I wonder what they are currently (especially with the new .mjs extension add we've been working on with IETF. This way I can see where I can help and take some concerns off your plate.
Thoughts?
As it relates to .mjs, resolve will absolutely add it to the default extension list the instant node ships it unflagged - but not before (that will also be when it's present in require.extensions in node).
@ljharb sounds like a plan! Any ref we can use to stick in the description / comment to watchdog?
Seems like you know better than me. I've merely been judging off PTSD of the community and in the classrooms. :-|
FWIW I'm totally against .mjs and believe it creates some unnecessary social fractures within the ecosystem but that's just my opinion not the community at large's.
A file extension is strictly necessary, since Module and Script have distinct (and ambiguous) parsing goals, and a file extension is the proper and sole way to disambiguate textual parsing goals - so this result was inevitable once the choice of two parse goals was made in TC39 back in 2013 or so.
@ljharb I knew this already. Not arguing file extensions. Arguing the community using the extension to mock the (dead) king of pop. Like I said...as an African American this is some bullshit. But I digress. Because the community always preaches diversity...as long as someone is making money off diversity at a conference or on a blog post touting "inclusivity". Apologize if you don't see why I would have an issue with this.
https://medium.com/dailyjs/es6-modules-node-js-and-the-michael-jackson-solution-828dc244b8b https://github.com/tc39/agendas/issues/322
I don't refer to mjs as anything related to "michael jackson", nor do i think it's mocking in any way - if anything, it's a reference to how people immediately think of him when they see "MJ" because he's so prolific - so I think you're looking a bit too hard for a reason to be upset.
@ljharb did anyone ask MJ about this? I'm not "looking for upset". We definitely have better things to do with our day. You may but I don't get paid for this. However, you are free to have your opinion. Others in the community who look like me feel the same way. Perhaps we are ALL over exaggerating. ¯_(ツ)_/¯ You may be right. I'll let them know your thoughts. 👍 I never ask anyone to change their mind. Only to have empathy without immediate dismissal.
He’s a public figure; he wouldn’t have the right nor the ability to stop people talking about him in a non-libelous way.
@ljharb there are laws set up against usage of name and likeliness of celebrities here in America. We can do it. Still doesn't make it right. And also a very slippery slope. Like i said, empathy without dismissal. However we are getting a tad off topic. I shall leave you be sir. Just here to help you.
An individual’s name isn’t culture, and referencing it (solely because of it sharing first letters in common) is not appropriation, cultural or otherwise.
@ljharb your opinion. And you are free to have this. I mentioned this to you already. But opinions aren't always facts and this conversation has been going on for a while now outside of this comment thread.
As long as you call it what it is "Module JavaScript" we see eye to eye. I think we both can (and should) agree on this. And that's definitely on topic sir. If that isn't our focus, we are introducing ulterior motives.
If you keep bringing up your complaint, here or anywhere, you make it on topic. And no, it’s not just opinion - merely referencing an individual’s name is not cultural appropriation, objectively, especially when no aspects of the individual are being referenced, literally or metaphorically - and when you claim it does, you weak the case against appropriation for us all.