round-core 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/cli.js +49 -0
- package/dist/index.d.ts +341 -0
- package/dist/vite-plugin.js +0 -31
- package/extension/.vscodeignore +5 -0
- package/extension/LICENSE +21 -0
- package/extension/cgmanifest.json +45 -0
- package/extension/extension.js +163 -0
- package/extension/images/round-config-dark.svg +10 -0
- package/extension/images/round-config-light.svg +10 -0
- package/extension/images/round-dark.svg +10 -0
- package/extension/images/round-light.svg +10 -0
- package/extension/javascript-language-configuration.json +241 -0
- package/extension/package-lock.json +97 -0
- package/extension/package.json +119 -0
- package/extension/package.nls.json +4 -0
- package/extension/round-0.1.0.vsix +0 -0
- package/extension/round-lsp/package-lock.json +185 -0
- package/extension/round-lsp/package.json +21 -0
- package/extension/round-lsp/src/round-transformer-lsp.js +248 -0
- package/extension/round-lsp/src/server.js +396 -0
- package/extension/snippets/javascript.code-snippets +266 -0
- package/extension/snippets/round.code-snippets +109 -0
- package/extension/syntaxes/JavaScript.tmLanguage.json +6001 -0
- package/extension/syntaxes/JavaScriptReact.tmLanguage.json +6066 -0
- package/extension/syntaxes/Readme.md +12 -0
- package/extension/syntaxes/Regular Expressions (JavaScript).tmLanguage +237 -0
- package/extension/syntaxes/Round.tmLanguage.json +290 -0
- package/extension/syntaxes/RoundInject.tmLanguage.json +20 -0
- package/extension/tags-language-configuration.json +152 -0
- package/extension/temp_astro/package-lock.json +912 -0
- package/extension/temp_astro/package.json +16 -0
- package/extension/types/round-core.d.ts +326 -0
- package/package.json +2 -1
- package/src/cli.js +53 -0
- package/src/compiler/vite-plugin.js +0 -35
- package/src/index.d.ts +341 -0
- package/src/runtime/context.js +12 -0
- package/src/runtime/dom.js +10 -0
- package/src/runtime/router.js +28 -0
- package/src/runtime/signals.js +38 -0
- package/src/runtime/store.js +7 -0
- package/vite.config.build.js +12 -0
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
{
|
|
2
|
+
"Round component": {
|
|
3
|
+
"prefix": "round:component",
|
|
4
|
+
"body": [
|
|
5
|
+
"export function ${1:ComponentName}() {",
|
|
6
|
+
"\treturn (",
|
|
7
|
+
"\t\t<div>",
|
|
8
|
+
"\t\t\t$0",
|
|
9
|
+
"\t\t</div>",
|
|
10
|
+
"\t);",
|
|
11
|
+
"}"
|
|
12
|
+
],
|
|
13
|
+
"description": "Create a Round component"
|
|
14
|
+
},
|
|
15
|
+
"signal": {
|
|
16
|
+
"prefix": "round:signal",
|
|
17
|
+
"body": [
|
|
18
|
+
"import { signal } from 'round-core';",
|
|
19
|
+
"",
|
|
20
|
+
"const ${1:name} = signal(${2:initial});",
|
|
21
|
+
"$0"
|
|
22
|
+
],
|
|
23
|
+
"description": "Create a signal()"
|
|
24
|
+
},
|
|
25
|
+
"bindable": {
|
|
26
|
+
"prefix": "round:bindable",
|
|
27
|
+
"body": [
|
|
28
|
+
"import { bindable } from 'round-core';",
|
|
29
|
+
"",
|
|
30
|
+
"const ${1:name} = bindable(${2:initial});",
|
|
31
|
+
"$0"
|
|
32
|
+
],
|
|
33
|
+
"description": "Create a bindable()"
|
|
34
|
+
},
|
|
35
|
+
"Route": {
|
|
36
|
+
"prefix": "round:route",
|
|
37
|
+
"body": [
|
|
38
|
+
"import { Route } from 'round-core';",
|
|
39
|
+
"",
|
|
40
|
+
"<Route route=\"${1:/}\" title=\"${2:Title}\">",
|
|
41
|
+
"\t$0",
|
|
42
|
+
"</Route>"
|
|
43
|
+
],
|
|
44
|
+
"description": "Insert a <Route> block"
|
|
45
|
+
},
|
|
46
|
+
"Suspense": {
|
|
47
|
+
"prefix": "round:suspense",
|
|
48
|
+
"body": [
|
|
49
|
+
"import { Suspense } from 'round-core';",
|
|
50
|
+
"",
|
|
51
|
+
"<Suspense fallback={<div>${1:Loading...}</div>}>",
|
|
52
|
+
"\t$0",
|
|
53
|
+
"</Suspense>"
|
|
54
|
+
],
|
|
55
|
+
"description": "Insert a <Suspense> block"
|
|
56
|
+
},
|
|
57
|
+
"Markdown": {
|
|
58
|
+
"prefix": "round:markdown",
|
|
59
|
+
"body": [
|
|
60
|
+
"import { Markdown } from 'round-core';",
|
|
61
|
+
"",
|
|
62
|
+
"<Markdown src=\"${1:./README.md}\" />$0"
|
|
63
|
+
],
|
|
64
|
+
"description": "Insert a <Markdown> component"
|
|
65
|
+
},
|
|
66
|
+
"Round if": {
|
|
67
|
+
"prefix": "round:if",
|
|
68
|
+
"body": [
|
|
69
|
+
"{if(${1:condition}){",
|
|
70
|
+
"\t$0",
|
|
71
|
+
"}}"
|
|
72
|
+
],
|
|
73
|
+
"description": "Round JSX superset if block"
|
|
74
|
+
},
|
|
75
|
+
"Round if/else": {
|
|
76
|
+
"prefix": "round:ifelse",
|
|
77
|
+
"body": [
|
|
78
|
+
"{if(${1:condition}){",
|
|
79
|
+
"\t$0",
|
|
80
|
+
"} else {",
|
|
81
|
+
"\t",
|
|
82
|
+
"}}"
|
|
83
|
+
],
|
|
84
|
+
"description": "Round JSX superset if/else block"
|
|
85
|
+
},
|
|
86
|
+
"Round for": {
|
|
87
|
+
"prefix": "round:for",
|
|
88
|
+
"body": [
|
|
89
|
+
"{for(${1:item} in ${2:list}){",
|
|
90
|
+
"\t$0",
|
|
91
|
+
"}}"
|
|
92
|
+
],
|
|
93
|
+
"description": "Round JSX superset for-in block"
|
|
94
|
+
},
|
|
95
|
+
"bind:value": {
|
|
96
|
+
"prefix": "round:bind:value",
|
|
97
|
+
"body": [
|
|
98
|
+
"<input bind:value={${1:state}} />$0"
|
|
99
|
+
],
|
|
100
|
+
"description": "Two-way bind:value"
|
|
101
|
+
},
|
|
102
|
+
"bind:checked": {
|
|
103
|
+
"prefix": "round:bind:checked",
|
|
104
|
+
"body": [
|
|
105
|
+
"<input type=\"checkbox\" bind:checked={${1:state}} />$0"
|
|
106
|
+
],
|
|
107
|
+
"description": "Two-way bind:checked"
|
|
108
|
+
}
|
|
109
|
+
}
|