Swift standard documentation comment

前端 未结 5 1317
小鲜肉
小鲜肉 2020-12-31 06:18

Is there a standard way to write documentation comment in the Swift language? Something equivalent to javadoc (Java) or docstrings (Python)?

example:



        
5条回答
  •  甜味超标
    2020-12-31 06:40

    You can see actual documentation standard here: http://nshipster.com/swift-documentation/

    Example:

    /**
        Lorem ipsum dolor sit amet.
    
        - parameter bar: Consectetur adipisicing elit.
    
        - returns: Sed do eiusmod tempor.
    */
    

    That works for me. Xcode 7.2

提交回复
热议问题