UNPKG

use-react-native-navigation

Version:

A utility library for a easier use of react-native-navigation library.

33 lines 1.01 kB
"use strict"; var __assign = (this && this.__assign) || function () { __assign = Object.assign || function(t) { for (var s, i = 1, n = arguments.length; i < n; i++) { s = arguments[i]; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; } return t; }; return __assign.apply(this, arguments); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.NavigationUtility = { /** * Set single component layout */ setLayoutComponent: function (props) { return { component: __assign({}, props), }; }, /** * Set stacked component layout */ setLayoutStackComponents: function (childrenProps, options) { var _this = this; return { stack: { children: childrenProps.map(function (prop) { return _this.setLayoutComponent(prop); }), options: options }, }; }, }; //# sourceMappingURL=utility.js.map