Create iOS framework using swift

168 views Asked by At

I am trying to create an iOS framework using swift. I follow this blog and also few others but the output is not the way I want.

Below is my original source file

public class TestClass: NSObject {

    // publicVar description
    public var publicVar: Int = 0

    // doSomething description
    public func doSomething() {
        print("doSomething method")
    }
}

After adding the framework into my project it's create an TestFramwork-Swift.h

enter image description here enter image description here

You can see it's not contain my description. I want the framework header files like Apple.

enter image description here

Can anyone help me to figure out this. I am not able to understand where I am doing wrong. I am also not able to add more swift files into my framework.

1

There are 1 answers

9
Michaël Azevedo On

Just use triple slash instead of double slash for comments you want to show in your framework headers.