Docs Quickstart Figma Flowbite
1.3.0
Getting started
Customize
Components
API Reference NEW
common / Class

BaseComponent

Decorators:@Directive
Generic types:TClass
Implements:OnInit

Base abstract component. Every flowbite-angular components has to extends on this one.

See Also

Properties

NameTypeDescription
contentClasses
Signal<TClass>

Computed signal storing the component classes used in its template

flowbiteId
r
WritableSignal<Guid>

Auto generated GUID for each flowbite-angular component

Its default value is 00000000-0000-0000-0000-000000000000, and is set to a random GUID inside the afterNextRender hook

injector
r
Injector

Injector instance injected to be used as an injector context where there is no default one.

Example usage
public ngOnInit(): void {
  afterNextRender(
     () => {},
     { injector: this.injector }
  );
}

Methods

abstract

fetchClass()

Function to load component's classes

Presentation
abstract fetchClass(): TClass;
Returns
TClass
Overload #1

Function to load component's classes

Presentation
abstract fetchClass(): TClass;
Returns
TClass

init()

Function loaded during OnInit lifecycle hook. It initialize requirments for the component.

Presentation
init(): void;
Returns
void

ngOnInit()

implements OnInit

Initialize component.

A call to verify and init function is done. Then a new Guid is set in the afterNextRender hook.

Presentation
ngOnInit(): void;
Returns
void
Flowbite

© 2019-2024 Flowbite™ is a registered trademark. All Rights Reserved.