-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtemplate.xml
123 lines (123 loc) · 8.16 KB
/
template.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
<templateSet group="lukesReactToolBox">
<template name="rtfc" value="import {FC} from "react"; interface $ComponentName$Props { prop: string; } export const $ComponentName$: FC<$ComponentName$Props> = ({prop}) => { return ( <div className={``}> {prop} </div> ); };" description="Typed React Functional Component with Tailwind div" toReformat="false" toShortenFQNames="true">
<variable name="ComponentName" expression="capitalize(fileNameWithoutExtension())" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="usee" value="useEffect(() => { },[])" description="Use Effect - on mount - no deps" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="af" value="const handleSomething = () => { };" description="Arrow Function" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="uses" value="const [state, setState] = useState(null)" description="useState with null value" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twdiv" value="<div className={`flex`}> </div>" description="Div with Tailwind Flex" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="rtern" value="{value ? ( <div className={``}></div> ) : ( <div className={``}></div> )}" description="Creates a styled Ternary operation for <div> rendering" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="rand" value="{value && (<div className={``}></div>)}" description="Creates a styled AND operation for <div> rendering" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twtern" value="${value ? "" : ""}" description="Creates an Inline Ternary for class styling based on value" toReformat="false" toShortenFQNames="true">
<context>
<option name="HTML" value="true" />
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twor" value="${value || ""}" description="Creates an inline OR operation for class styling based on a nullable values" toReformat="false" toShortenFQNames="true">
<context>
<option name="HTML" value="true" />
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twand" value="${value && ""}" description="Creates an inline AND operation for class styling based on a value" toReformat="false" toShortenFQNames="true">
<context>
<option name="HTML" value="true" />
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twrow" value="<div className={`flex flex-row gap-4`}> </div>" description="Creates a Tailwind row" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="twcol" value="<div className={`flex flex-col gap-4`}> </div>" description="Creates a Tailwind column" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="rfc" value="export default function $ComponentName$() { return ( <div className={``}> </div> ); };" description="Creates a simple Functional Component" toReformat="false" toShortenFQNames="true">
<variable name="ComponentName" expression="capitalize(fileNameWithoutExtension())" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwtfc" value="import {FunctionComponent} from "react"; import {View, Text, ViewStyle} from "react-native"; interface OwnProps { style: ViewStyle; } type Props = OwnProps; export const $ComponentName$: FunctionComponent<Props> = (props) => { const {style} = props return ( <View style={style} className={``}> </View> ); };" description="Creates a NativeWind Type Functional Component" toReformat="false" toShortenFQNames="true">
<variable name="ComponentName" expression="capitalize(fileNameWithoutExtension())" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwfc" value="import {View, Text} from "react-native"; export default function $ComponentName$() { 	return ( 		<View className={``}> 		</View> 	); };" description="Creates a simple NativeWind Functional Component" toReformat="false" toShortenFQNames="true">
<variable name="ComponentName" expression="capitalize(fileNameWithoutExtension())" defaultValue="" alwaysStopAt="true" />
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwview" value="<View className={``}> </View>" description="Creates a NativeWind View with className" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwtext" value="<Text className={``}> </Text>" description="Creates a NativeWind Text with className" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwtern" value="{value ? ( <View className={``}></View> ) : ( <View className={``}></View> )}" description="Creates a NativeWind Ternary Opration for <View>" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
<template name="nwand" value="{value && (<View className={``}></View>)}" description="Creates a NativeWind AND Operation for <View>" toReformat="false" toShortenFQNames="true">
<context>
<option name="JAVA_SCRIPT" value="true" />
<option name="TypeScript" value="true" />
</context>
</template>
</templateSet>