I am not sure where we are since the last comment was 3 months back, but I will try to address concerns in some of the previous comments.
#12: We can't use type: library
as that is the default for composer.json if not specified. Further, this is actually used by PHP libraries. See https://github.com/symfony/http-kernel/blob/master/composer.json for example. This means we should really use the name. If we can submit a PR to the chosen library to change it to something like 'npm-asset', then we don't have to worry about this (once it gets merged and tagged).
#19, #20: I think what the documentation says is that the installer-paths
of only the root composer.json is used, not in the library's composer.json file. To workaround this, documentation in chosen module should just direct people to add the entry to installer-paths
in their composer.json file.
I'll review the patch in #18 and see if I can help.