Socket
Socket
Sign inDemoInstall

@expo/config-types

Package Overview
Dependencies
0
Maintainers
24
Versions
84
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @expo/config-types

Types for the Expo config object app.config.ts


Version published
Weekly downloads
990K
decreased by-18.8%
Maintainers
24
Install size
79.6 kB
Created
Weekly downloads
 

Package description

What is @expo/config-types?

The @expo/config-types package provides TypeScript definitions for Expo config (`app.json` / `app.config.js`). It allows developers to have type checking and auto-completion when working with Expo configuration files, ensuring that the configuration adheres to the expected structure and types defined by Expo.

What are @expo/config-types's main functionalities?

Type checking for app.json

This code sample demonstrates how to define an Expo app configuration with type checking. It ensures that the configuration object adheres to the structure and types expected by Expo, providing auto-completion and preventing common mistakes.

import { ExpoConfig } from '@expo/config-types';

const config: ExpoConfig = {
  name: 'My Expo App',
  slug: 'my-expo-app',
  version: '1.0.0',
  orientation: 'portrait',
  icon: './path/to/icon.png',
  splash: {
    image: './path/to/splash.png',
    resizeMode: 'contain',
    backgroundColor: '#ffffff'
  },
  updates: {
    fallbackToCacheTimeout: 0
  },
  assetBundlePatterns: ['**/*'],
  ios: {
    supportsTablet: true
  },
  android: {
    adaptiveIcon: {
      foregroundImage: './path/to/foreground.png',
      backgroundColor: '#FFFFFF'
    }
  }
};

Other packages similar to @expo/config-types

Readme

Source

config-types

Types for the Expo config object app.config.ts.

Usage

import { ExpoConfig } from '@expo/config-types';

export default (): ExpoConfig => {
  return {
    name: 'My App',
    slug: 'my-app',
  };
};

Contributing

This package is 100% generated using the versioned JSON schemas from the Expo server.

  • yarn generate - uses the major version from the package.json.
  • yarn generate --path ../../../universe/server/www/xdl-schemas/UNVERSIONED-schema.json - uses the latest version from your local directory.
  • yarn generate 39 - uses the given version.
  • yarn generate unversioned - uses the latest version.

Keywords

FAQs

Last updated on 16 Jul 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc