Problem
In contributing_libraries.md, the documentation for the optional npmFilePath field is a bit confusing:
(Optional) npmFilePath: A path like 'dist/library.min.js' if a specific file in the library should be used from npm. You can test this out by going to https://cdn.jsdelivr.net/npm/packageName -- if that doesn't work, try https://cdn.jsdelivr.net/npm/packageName/path/to/file.js and put the path you added into this property
When I followed these instructions while submitting a library, I wasn't sure:
- when
npmFilePath is actually needed
- how I was supposed to discover the correct relative path
Suggested improvement
Problem
In contributing_libraries.md, the documentation for the optional
npmFilePathfield is a bit confusing:When I followed these instructions while submitting a library, I wasn't sure:
npmFilePathis actually neededSuggested improvement
Explain first that most libraries do not need
npmFilePath.Provide simple step-by-step instructions:
https://cdn.jsdelivr.net/npm/packageNameloads the library. If it does, you're all set.https://www.jsdelivr.com/package/npm/packageNameto locate the JavaScript file and use its relative path asnpmFilePath.