Skip to main content
Version: 2.0.0-alpha

Interface: FirebaseCMSAppProps

Main entry point that defines the CMS configuration

Properties​

HomePage​

• Optional HomePage: ComponentType<{}>

In case you need to override the home page. You may want to use {@link useNavigation} in order to get the resolved navigation.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:141


LoginViewProps​

• Optional LoginViewProps: Partial<FirebaseLoginViewProps>

Additional props passed to the login view. You can use this props to disable registration in password mode, or to set up an additional message.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:158


allowSkipLogin​

• Optional allowSkipLogin: boolean

If authentication is enabled, allow the user to access the content without login.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:72


authentication​

• Optional authentication: boolean | Authenticator<User>

Do the users need to log in to access the CMS. You can specify an Authenticator function to discriminate which users can access the CMS or not. If not specified, authentication is enabled but no user restrictions apply

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:56


baseCollectionPath​

• Optional baseCollectionPath: string

Default path under the collection routes of the CMS will be created

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:151


basePath​

• Optional basePath: string

Default path under the navigation routes of the CMS will be created

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:146


collectionOverrideHandler​

• Optional collectionOverrideHandler: CollectionOverrideHandler

Used to override collections based on the collection path and entityId. This resolver allows to override the collection for specific entities, or specific collections, app wide. This overrides collections all through the app.

You can also override collections in place, when using useSideEntityController

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:127


collections​

• Optional collections: EntityCollection<any, string, User>[] | EntityCollectionsBuilder

List of the mapped collections in the CMS. Each entry relates to a collection in the root database. Each of the navigation entries in this field generates an entry in the main menu.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:41


dateTimeFormat​

• Optional dateTimeFormat: string

Format of the dates in the CMS. Defaults to 'MMMM dd, yyyy, HH:mm:ss'

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:113


firebaseConfig​

• Optional firebaseConfig: Record<string, unknown>

Firebase configuration of the project. If you afe deploying the app to Firebase hosting, you don't need to specify this value

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:78


fontFamily​

• Optional fontFamily: string

Font family string e.g. '"Roboto", "Helvetica", "Arial", sans-serif'

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:102


locale​

• Optional locale: Locale

Locale of the CMS, currently only affecting dates

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:118


• Optional logo: string

Logo to be displayed in the drawer of the CMS

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:33


name​

• name: string

Name of the app, displayed as the main title and in the tab title

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:28


primaryColor​

• Optional primaryColor: string

Primary color of the theme of the CMS

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:90


secondaryColor​

• Optional secondaryColor: string

Secondary color of the theme of the CMS

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:95


signInOptions​

• Optional signInOptions: (FirebaseSignInProvider | FirebaseSignInOption)[]

List of sign in options that will be displayed in the login view if authentication is enabled. You can pass Firebase providers strings, such as firebase.auth.GoogleAuthProvider.PROVIDER_ID or include addtional config such as scopes or custom parameters {@see FirebaseSignInOption} Defaults to Google sign in only.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:66


textSearchController​

• Optional textSearchController: FirestoreTextSearchController

Use this controller to return text search results as document ids, that get then fetched from Firestore.

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:134


toolbarExtraWidget​

• Optional toolbarExtraWidget: ReactNode

A component that gets rendered on the upper side of the main toolbar

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:107


views​

• Optional views: CMSView[] | CMSViewsBuilder

Custom additional views created by the developer, added to the main navigation

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:47

Methods​

onFirebaseInit​

â–¸ Optional onFirebaseInit(config): void

Optional callback after Firebase has been initialised. Useful for using the local emulator or retrieving the used configuration.

Parameters​

NameType
configobject

Returns​

void

Defined in​

lib/src/firebase_app/FirebaseCMSAppProps.tsx:85