object-path icon indicating copy to clipboard operation
object-path copied to clipboard

Rename the main file more meaningful

Open pvnr0082t opened this issue 8 years ago • 6 comments

Hi @mariocasciaro , I'm a member of cdnjs, we want to host this library. Because I found that the main file is index.js, I'd like to discuss if it's possible to name the filename with meaningful name like object-path.js. Thank you.

https://github.com/cdnjs/cdnjs/issues/9559

pvnr0082t avatar Dec 10 '16 04:12 pvnr0082t

Hi @pvnr0082t , could you please elaborate the reason for the renaming?

mariocasciaro avatar Dec 10 '16 17:12 mariocasciaro

@mariocasciaro It's just a suggestion for better naming scheme and it will let users easily know what files they include. If you still want to use index.js, that's okay. It's up to you. :smile:

pvnr0082t avatar Dec 11 '16 01:12 pvnr0082t

Sure, I'll take it in consideration. I'll work on it after the holiday season ;)

mariocasciaro avatar Dec 20 '16 10:12 mariocasciaro

@mariocasciaro , will you get to this? I requested object-path to be included in cdnjs.

gerhardcit avatar Jan 27 '17 17:01 gerhardcit

@gerhardcit It's a delicate change that could break people's code. I need to think this through. This will probably need a major version bump.

mariocasciaro avatar Feb 10 '17 20:02 mariocasciaro

You know the saying, "if the mountain won't come to Muhammad...". The mountain of npm libraries are using index.js and it won't move to meaningful, semantic names. CDNJS should adapt to that, there's too much hassle to negotiate every single repo to be renamed. Plus, some of CDNJS competitors (Rawgit for example) are already serving all libraries, no matter with meaningful names or with index.js.

See: https://cdn.rawgit.com/mariocasciaro/object-path/99d9d300/index.js it's served no problem.

Why can't CDNJS do that too?

I wonder what was the reason of writing this comment.

Meaningful name will significantly ease finding all say object-path.js with file explorer and then drag those to your VC/ST editor. That's just one reason. In gulp.js it's also helpful having human readable library names. Since there's no convention in where the main file should reside (dist/src/libs or just /) and what its name should be, it's up to community to vote for renaming.

englishextra avatar Nov 22 '20 23:11 englishextra