Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to customize a swift-style to replace the C-style? #19

Open
iT-Boyer opened this issue Dec 15, 2021 · 0 comments
Open

How to customize a swift-style to replace the C-style? #19

iT-Boyer opened this issue Dec 15, 2021 · 0 comments

Comments

@iT-Boyer
Copy link

(docstr--c-style-search-string 1)

(defun docstr-trigger-swift (&rest _)
  "Trigger document string inside Swift."
  (when (and (memq major-mode docstr-swift-modes)
             (docstr--doc-valid-p)
             (docstr-util-looking-back "///" 3))
    (insert " ")
    (docstr--insert-doc-string (docstr--c-style-search-string 1))))
 /// [summary]
    /// 
    /// - arr1: [description]
    /// - arr2: [description]
    /// - returns: [description]  

The default swift language annotation is the C language style. How to customize a swift style to replace the C language style?

this swift style like:

/// <#Description#>
    /// - Parameters:
    ///   - arr1: <#arr1 description#>
    ///   - arr2: <#arr2 description#>
    /// - Returns: <#description#>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant