Skip to content

Commit

Permalink
feat(macros): hide command macro from docs, closes #4550 (#4556)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasfernog authored Jul 1, 2022
1 parent 35b5378 commit d4cdf80
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
5 changes: 5 additions & 0 deletions .changes/doc-hide-command-macro.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"tauri-macros": patch
---

Add `#[doc(hidden)]` attribute to the `#[command]` generated macro.
1 change: 1 addition & 0 deletions core/tauri-macros/src/command/wrapper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ pub fn wrapper(attributes: TokenStream, item: TokenStream) -> TokenStream {
#function

#maybe_macro_export
#[doc(hidden)]
macro_rules! #wrapper {
// double braces because the item is expected to be a block expression
($path:path, $invoke:ident) => {{
Expand Down
14 changes: 7 additions & 7 deletions examples/api/src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d4cdf80

Please sign in to comment.