MCPcopy Create free account
hub / github.com/composify-js/composify / HStack

Function HStack

examples/expo/components/HStack/HStack.tsx:26–62  ·  view source on GitHub ↗
({
  flex,
  gap,
  alignHorizontal = 'start',
  alignVertical = 'stretch',
  width,
  height,
  padding,
  margin,
  backgroundColor,
  children,
})

Source from the content-addressed store, hash-verified

24}>;
25
26export const HStack: FC<Props> = ({
27 flex,
28 gap,
29 alignHorizontal = 'start',
30 alignVertical = 'stretch',
31 width,
32 height,
33 padding,
34 margin,
35 backgroundColor,
36 children,
37}) => (
38 <View
39 style={[
40 styles.base,
41 styles[`justify-${alignHorizontal}`],
42 styles[`align-${alignVertical}`],
43 {
44 flex,
45 gap,
46 width,
47 height,
48 paddingTop: padding?.top,
49 paddingRight: padding?.right,
50 paddingBottom: padding?.bottom,
51 paddingLeft: padding?.left,
52 marginTop: margin?.top,
53 marginRight: margin?.right,
54 marginBottom: margin?.bottom,
55 marginLeft: margin?.left,
56 backgroundColor,
57 },
58 ]}
59 >
60 {children}
61 </View>
62);
63
64const styles = StyleSheet.create({
65 base: {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected