A universal module that gets native application information such as its ID, app name, and build version at runtime
Overall
score
98%
Build a React Native component that displays essential application metadata to users in a settings or about screen.
Create a React Native component called AppInfoDisplay that:
getAppMetadata() that returns an object containing all four metadata fieldsnull (e.g., on web), display "Not Available" insteadgetAppMetadata() function returns an object with all four fields @test@generates
import React from 'react';
/**
* Metadata object containing application information
*/
export interface AppMetadata {
name: string | null;
id: string | null;
version: string | null;
build: string | null;
}
/**
* Props for AppInfoDisplay component
*/
export interface AppInfoDisplayProps {
style?: object;
}
/**
* React Native component that displays application metadata
*/
export function AppInfoDisplay(props: AppInfoDisplayProps): React.ReactElement;
/**
* Gets current application metadata
* @returns Object containing app name, id, version, and build
*/
export function getAppMetadata(): AppMetadata;Provides access to native application information including name, ID, version, and build number.
@satisfied-by
Install with Tessl CLI
npx tessl i tessl/npm-expo-application