#[non_exhaustive]pub struct JSDoc(/* private fields */);Expand description
JSDoc language exporter.
Implementations§
Source§impl JSDoc
impl JSDoc
Sourcepub fn header(self, header: impl Into<Cow<'static, str>>) -> Self
pub fn header(self, header: impl Into<Cow<'static, str>>) -> Self
Configure a header for the file.
This is perfect for configuring lint ignore rules or other file-level comments.
Sourcepub fn bigint(self, bigint: BigIntExportBehavior) -> Self
pub fn bigint(self, bigint: BigIntExportBehavior) -> Self
Configure the BigInt handling behaviour
Sourcepub fn branded_type_impl(
self,
builder: impl for<'a> Fn(BrandedTypeExporter<'a>, &Branded) -> Result<Cow<'static, str>, Error> + Send + Sync + 'static,
) -> Self
pub fn branded_type_impl( self, builder: impl for<'a> Fn(BrandedTypeExporter<'a>, &Branded) -> Result<Cow<'static, str>, Error> + Send + Sync + 'static, ) -> Self
Configure how specta_typescript::branded! types are rendered.
See Exporter::branded_type_impl for details.
Sourcepub fn with_serde(self, mode: SerdeMode) -> Self
pub fn with_serde(self, mode: SerdeMode) -> Self
Configure the exporter to use specta-serde with the specified mode
Sourcepub fn with_serde_serialize(self) -> Self
pub fn with_serde_serialize(self) -> Self
Configure the exporter to export the types for #[derive(serde::Serialize)]
Sourcepub fn with_serde_deserialize(self) -> Self
pub fn with_serde_deserialize(self) -> Self
Configure the exporter to export the types for #[derive(serde::Deserialize)]
Trait Implementations§
Auto Trait Implementations§
impl Freeze for JSDoc
impl !RefUnwindSafe for JSDoc
impl Send for JSDoc
impl Sync for JSDoc
impl Unpin for JSDoc
impl UnsafeUnpin for JSDoc
impl !UnwindSafe for JSDoc
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more