Добавить в избранное
Форум
Правила сайта "Мир Книг"
Группа в Вконтакте
Подписка на книги
Правообладателям
Найти книгу:
Навигация
Вход на сайт
Регистрация



Реклама



Название: javascript Native Interface: Build cross-platform apps with native performance
Автор: Tony Gaitatzis
Издательство: BackupBrain
Год: 2024
Страниц: 194
Язык: английский
Формат: pdf, epub
Размер: 10.9 MB

About this Book:

In mobile development, there is a trade-off between portability code and fast execution. A new feature of React Native called javascript Native Interface (JSI) removes that trade-off by allowing developers to write portable code that executes as binary code on the native device.

javascript Interface (JSI) offers developers to the convenience of cross-platform apps with the performance of native apps. It lets developers to write functions in C++ that can be called directly from javascript, for example in a React Native front-end. It works by combining two existing features of React Native:
• The native code (for example Swift or Java) can call binary functions from compiled C++
• React Native javascript can call properly-defined native functions

C++ code can be written in a cross-platform way and compiled for a variety of devices, such as Android and iOS, as long as it doesn’t work on device-specific or platform-specific features such as user interfaces or certain hardware such as sensors or specific camera features. Since both the javascript and C++ are cross-platform and the native layer can bind these languages together, it is possible to create React Native apps for several platforms with one code base. javascript Native Interface code must be written so that functions and data types are compatible with the javascript type system, and those functions must be properly exported to the javascript environment. This book will walk you through understanding how to set up a React Native project to use JSI, and how to implement common function types in JSI, including those that take or return arrays and complex object types, Promises, and multi-threaded functions.

javascript Interface (JSI) is a lightweight, general-purpose API provided by Facebook for interacting with javascript data types and functions in C++ code. Introduced in the context of React Native, JSI offers a way to call C++ functions directly from javascript and vice versa. Before JSI, React Native used a “Native Bridge” feature, which required that developers write native code in the device-native language, for example Swift on iOS and Java or Kotlin on Android. React Native developers who wanted to have the performance of a native app therefore needed to maintain two code-bases for the same features. JSI solves this by allowing developers to maintain high-performance code in only one language: C++. While JSI brings numerous advantages, especially for complex and performance-critical applications, it's worth noting that it requires a good understanding of both C++ and javascript, as well as the internals of React Native. As such, it's often used for building advanced features, or optimizing performance-critical paths.

What You Will Learn:

This book teaches you how to write JSI code so that you can have write-once, run-everywhere mobile apps that feel like they are written in native code.

You will learn how to set up a JSI project on MacOS, Windows, and Linux. It will teach you how to register native functions, and how to accept any type of parameter and return any type of value. Importantly, this also includes working with objects, arrays, callback functions, and promises.

Who This Book Is For:
This book is intended for programmers, engineers, and technology enthusiasts who want to learn about mobile development.

Скачать javascript Native Interface: Build cross-platform apps with native performance







ОТСУТСТВУЕТ ССЫЛКА/ НЕ РАБОЧАЯ ССЫЛКА ЕСТЬ РЕШЕНИЕ, ПИШИМ СЮДА!







Автор: Ingvar16 2-06-2024, 18:59 | Напечатать |
 
Уважаемый посетитель, Вы зашли на сайт как незарегистрированный пользователь.





С этой публикацией часто скачивают:

Посетители, находящиеся в группе Гости, не могут оставлять комментарии к данной публикации.


 MirKnig.Su  ©2024     При использовании материалов библиотеки обязательна обратная активная ссылка    Политика конфиденциальности