You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

@react-native-community/cli-platform-apple

Package Overview
Dependencies
Maintainers
34
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@react-native-community/cli-platform-apple

This package is part of the [React Native CLI](../../README.md). It contains utilities for building reusable commands targetting Apple platforms.


Version published
Weekly downloads
637K
decreased by-15.6%
Maintainers
34
Created
Weekly downloads
 

Package description

What is @react-native-community/cli-platform-apple?

@react-native-community/cli-platform-apple is a part of the React Native CLI tools specifically designed to handle tasks related to the Apple ecosystem, such as building and running iOS applications. It provides a set of commands and utilities to streamline the development process for React Native apps on iOS.

What are @react-native-community/cli-platform-apple's main functionalities?

Run iOS Application

This command builds and runs the iOS application on a simulator or a connected device. It simplifies the process of launching the app for development and testing.

npx react-native run-ios

Build iOS Application

This command builds the iOS application, generating the necessary build artifacts. It is useful for preparing the app for distribution or further testing.

npx react-native build-ios

Link Native Dependencies

This command links native dependencies to the iOS project. It automates the process of adding native modules to the Xcode project, making it easier to integrate third-party libraries.

npx react-native link

Other packages similar to @react-native-community/cli-platform-apple

Readme

Source

@react-native-community/cli-platform-apple

This package is part of the React Native CLI. It contains utilities for building reusable commands targetting Apple platforms.

Installation

yarn add @react-native-community/cli-platform-apple

Usage

This package is intended to be used internally in React Native CLI and by out of tree platforms.

It exports builder commands that can be used to create custom run-, log- and build- commands for example: yarn run-<oot-platform>.

Inside of <oot-platform>/packages/react-native/react-native.config.js:

const {
  getBuildOptions,
  createBuild,
} = require('@react-native-community/cli-platform-apple');

const buildVisionOS = {
  name: 'build-visionos',
  description: 'builds your app for visionOS platform',
  func: createBuild({platformName: 'visionos'}),
  examples: [
    {
      desc: 'Build the app for visionOS in Release mode',
      cmd: 'npx react-native build-visionos --mode "Release"',
    },
  ],
  options: getBuildOptions({platformName: 'visionos'}),
};

module.exports = {
  commands: [buildVisionOS], // <- Add command here
  //..
};

cli-platform-apple also exports utilities to create OOT platform config.

  • getProjectConfig() - creates project config for given platform
  • getDependencyConfg() - creates dependency config for given platform

Example (<oot-platform>/packages/react-native/react-native.config.js):

platforms: {
    visionos: {
      npmPackageName: '@callstack/react-native-visionos',
      projectConfig: getProjectConfig({platformName: 'visionos'}),
      dependencyConfig: getDependencyConfg({platformName: 'visionos'}),
    },
    ..
  },

FAQs

Package last updated on 18 Jul 2024

Did you know?

Socket

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
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc