react-native-global-styler
Version:
Lightweight and developer-friendly React Native styling toolkit with prebuilt styled components and a powerful useGlobalStyler hook for shorthand props like m_10, radius_12, resize_cover, and more.
10 lines (9 loc) • 359 B
JavaScript
import * as React from 'react';
import { View } from 'react-native';
import useGlobalStyler from '../styles/useGlobalStyler';
;
const GSView = (props) => {
const generatedStyles = useGlobalStyler(props);
return (React.createElement(View, Object.assign({}, props, { style: [generatedStyles, props.style] }), props.children));
};
export default GSView;