@ng-doc/app
Version:
<!-- PROJECT LOGO --> <br /> <div align="center"> <a href="https://github.com/ng-doc/ng-doc"> <img src="https://ng-doc.com/assets/images/ng-doc.svg?raw=true" alt="Logo" height="150px"> </a>
50 lines (41 loc) • 1.11 kB
TypeScript
import { ViewContainerRef, Type } from '@angular/core';
import { NgDocTocItem } from '@ng-doc/app/interfaces';
import { NgDocPlaygroundProperty } from '@ng-doc/core/interfaces';
/**
*
* @param value
*/
declare function asBoolean(value: unknown): boolean;
/**
*
* @param viewContainer
* @param component
* @param inputs
*/
declare function createComponent<T>(viewContainer: ViewContainerRef, component: Type<T>, inputs?: object): void;
/**
*
* @param html
*/
declare function formatHtml(html: string): Promise<string>;
/**
* Generate table of contents, only for headings with id
* @param container
* @param headings
*/
declare function generateToc(container: HTMLElement): NgDocTocItem[];
/**
* Check if the OS theme is dark
*/
declare function isDarkOsTheme(): boolean;
/**
*
* @param url
*/
declare function isExternalLink(url: string): boolean;
/**
*
* @param obj
*/
declare function isPlaygroundProperty(obj: Record<string, any>): obj is NgDocPlaygroundProperty;
export { asBoolean, createComponent, formatHtml, generateToc, isDarkOsTheme, isExternalLink, isPlaygroundProperty };