0

I want to build a frontend in kotlin/react. I want it to be able to depend on common artefacts written in kotlin. These artefacts will be in my local maven repo. How do I reference these in package.json?

4

1 回答 1

1

You can not reference this in your package.json file, package.json describes only npm artifacts. If one will put jar file to an npm package in theory you'll be able to access it but again it's most likely not something you actually looking for - the physical accessibility of jar doesn't actually means it content can be used as a source code.

You can achieve this, however, using gradle. It won't be exaggeration to say that modern Kotlin/JS development is very, very challenging (to put it mildly) without using gradle. In gradle you can download any jar, unpack it and add all relevant content to sourceset.

于 2019-10-31T12:22:42.910 回答