Can I depend on artifacts published with old multi...
# multiplatform
h
Can I depend on artifacts published with old multiplatform structure in my
kotlin-multipplatform
module?
l
Sure, there are no known limitations on that. Why do you ask?
h
I'm trying to import https://github.com/square/okio in a common module. I can see jar in the
External Libraries
of my IDE, but autocomplete and imports are not working.
l
Can you share an example project, please? Is the code from the library actually resolved if the import statements are written manually?
h
Seems like it. Some classes with read imports are compiled fine. IS there a solution?
Nevermind. After fixing all compile unrelated to red imports it compiles fine, but fails on task
compileKotlinMetadata
,
Unresolver reference
for the library I'm importing.
l
Can you show how do you configure the dependency?
h
l
For the dependency you specified,
JVM
artifact comes, not the
common
one — that is the key point why the highlighting isn’t working properly for
common
module, as well as the build fails. It expects an appropriate platform-agnostic artifact, not the platform-specific. At the same time, I searched through GitHub repositories and failed to find a usage of the library with multiplatfrom projects to reference the proper artifact dependency format for a common module 😞
h
Oh you're right, the don't have a common artifact. Thanks for help.
👍🏻 1