If I want a list of methods in a KClass on Kotlin ...
# multiplatform
m
If I want a list of methods in a KClass on Kotlin JS, am I out of luck? It feels like I am but just checking.
c
If you are on Kotlin JS you should be able to use the native JS approach of listing member functions: https://stackoverflow.com/questions/31054910/get-functions-methods-of-a-class
b
Yeah, but be warned that it will surface shitloads of internal methods. Also if you're using ir, everything is mangled by default unless @JsExported
m
Thanks for the responses. It looks like I'm out of luck on this angle. Thankfully I can get what I need done with a kotlinx.ast at build time. Basically I'm writing a couple fancy lining checks, that look at multiple files (so I can't use a custom ktlint ruleset), and help enforce code quality.