Skip to content

Commit 3bc9577

Browse files
committed
✨ feat: ejs model 添加相关路径
1 parent 8e1de6c commit 3bc9577

5 files changed

Lines changed: 211 additions & 210 deletions

File tree

package.json

Lines changed: 187 additions & 187 deletions
Original file line numberDiff line numberDiff line change
@@ -1,189 +1,189 @@
11
{
2-
"name": "lowcode",
3-
"displayName": "lowcode",
4-
"description": "低代码工具",
5-
"author": "wjkang <ruoxieme@gmail.com>",
6-
"version": "1.2.9",
7-
"icon": "asset/icon.png",
8-
"publisher": "wjkang",
9-
"repository": "https://github.com/lowcoding/lowcode-vscode",
10-
"main": "./build/extension.js",
11-
"scripts": {
12-
"vscode:prepublish": "yarn run compile",
13-
"compile": "webpack --mode production",
14-
"compile:tsc": "tsc -p ./",
15-
"webview:dev-vue": "yarn --cwd \"webview-vue\" dev",
16-
"webview:build-vue": "yarn --cwd \"webview-vue\" build",
17-
"webview:dev-react": "yarn --cwd \"webview-react\" dev",
18-
"webview:build-react": "yarn --cwd \"webview-react\" build",
19-
"lint": "eslint src --ext ts",
20-
"watch": "webpack --mode development",
21-
"pretest": "yarn run compile:tsc",
22-
"test:js": "node ./build/test/runTest.js",
23-
"test": "node ./build/test/runTest.js"
24-
},
25-
"engines": {
26-
"vscode": "^1.42.0"
27-
},
28-
"categories": [
29-
"Other"
30-
],
31-
"keywords": [
32-
"yapi",
33-
"typescript",
34-
"generate code",
35-
"json",
36-
"lowcode"
37-
],
38-
"activationEvents": [
39-
"*"
40-
],
41-
"contributes": {
42-
"commands": [
43-
{
44-
"command": "yapi-code.generateCodeByWebview",
45-
"title": "可视化生成代码"
46-
},
47-
{
48-
"command": "yapi-code.generateCode",
49-
"title": "生成代码"
50-
},
51-
{
52-
"command": "lowcode.openDownloadMaterials",
53-
"title": "下载物料"
54-
},
55-
{
56-
"command": "yapi-code.addSnippet",
57-
"title": "添加代码片段"
58-
},
59-
{
60-
"command": "lowcode.quickGenerateBlock",
61-
"title": "快速创建区块"
62-
}
63-
],
64-
"menus": {
65-
"editor/context": [
66-
{
67-
"submenu": "lowcode/editor/context",
68-
"group": "1_lowcode@1"
69-
}
70-
],
71-
"explorer/context": [
72-
{
73-
"submenu": "lowcode/explorer/context",
74-
"group": "2_lowcode@1",
75-
"when": "explorerResourceIsFolder"
76-
}
77-
],
78-
"lowcode/editor/context": [
79-
{
80-
"command": "yapi-code.generateCodeByWebview",
81-
"group": "lowcode@1"
82-
},
83-
{
84-
"command": "yapi-code.generateCode",
85-
"group": "lowcode@2"
86-
},
87-
{
88-
"command": "lowcode.openDownloadMaterials",
89-
"group": "lowcode@3"
90-
},
91-
{
92-
"command": "yapi-code.addSnippet",
93-
"group": "lowcode@4"
94-
}
95-
],
96-
"lowcode/explorer/context": [
97-
{
98-
"command": "lowcode.quickGenerateBlock",
99-
"group": "lowcode@1"
100-
},
101-
{
102-
"command": "yapi-code.generateCodeByWebview",
103-
"group": "lowcode@2"
104-
},
105-
{
106-
"command": "lowcode.openDownloadMaterials",
107-
"group": "lowcode@3"
108-
}
109-
]
110-
},
111-
"submenus": [
112-
{
113-
"id": "lowcode/editor/context",
114-
"label": "Low Code"
115-
},
116-
{
117-
"id": "lowcode/explorer/context",
118-
"label": "Low Code"
119-
}
120-
],
121-
"viewsContainers": {
122-
"activitybar": [
123-
{
124-
"id": "lowcodeApp",
125-
"title": "lowcode",
126-
"icon": "asset/activitybar.svg"
127-
}
128-
]
129-
},
130-
"views": {
131-
"lowcodeApp": [
132-
{
133-
"id": "lowcode.welcome",
134-
"name": "Welcome"
135-
}
136-
]
137-
},
138-
"viewsWelcome": [
139-
{
140-
"view": "lowcode.welcome",
141-
"contents": "[打开文件夹](command:lowcode.openFolderForceNewWindow)\n[创建应用](command:lowcode.openScaffold)\n[设置](command:lowcode.openConfig)\n查看[文档](https://lowcoding.gitee.io)以学习如何在 VS Code 中如何使用 lowcode。"
142-
}
143-
]
144-
},
145-
"devDependencies": {
146-
"@types/copy-paste": "^1.1.30",
147-
"@types/debug": "^4.1.5",
148-
"@types/ejs": "^3.0.4",
149-
"@types/fs-extra": "^9.0.1",
150-
"@types/glob": "^7.1.1",
151-
"@types/mocha": "^7.0.2",
152-
"@types/node": "^13.11.0",
153-
"@types/prettier": "^2.0.2",
154-
"@types/readable-stream": "^2.3.9",
155-
"@types/urijs": "^1.19.9",
156-
"@types/vscode": "1.42.0",
157-
"@typescript-eslint/eslint-plugin": "^4.18.0",
158-
"@typescript-eslint/parser": "^4.18.0",
159-
"eslint": "^6.8.0",
160-
"eslint-config-airbnb-base": "^14.2.1",
161-
"eslint-config-prettier": "^8.3.0",
162-
"eslint-plugin-import": "^2.24.0",
163-
"eslint-plugin-prettier": "^3.3.1",
164-
"glob": "^7.1.6",
165-
"mocha": "^7.1.2",
166-
"prettier": "^2.2.1",
167-
"ts-loader": "^8.0.3",
168-
"typescript": "^4.3.5",
169-
"vscode-test": "^1.3.0",
170-
"webpack": "^4.44.1",
171-
"webpack-cli": "^3.3.12"
172-
},
173-
"dependencies": {
174-
"axios": "^0.19.2",
175-
"copy-paste": "^1.3.0",
176-
"directory-tree": "^2.2.4",
177-
"ejs": "^3.1.3",
178-
"execa": "^4.0.3",
179-
"fs-extra": "^9.0.1",
180-
"generate-schema": "^2.6.0",
181-
"globby": "^11.0.1",
182-
"is-url": "^1.2.4",
183-
"json-schema-to-typescript": "^9.1.1",
184-
"strip-comments": "^2.0.1",
185-
"strip-json-comments": "^3.1.1",
186-
"tar": "^6.0.5",
187-
"typescript-json-schema": "^0.50.1"
188-
}
2+
"name": "lowcode",
3+
"displayName": "lowcode",
4+
"description": "低代码工具",
5+
"author": "wjkang <ruoxieme@gmail.com>",
6+
"version": "1.3.0",
7+
"icon": "asset/icon.png",
8+
"publisher": "wjkang",
9+
"repository": "https://github.com/lowcoding/lowcode-vscode",
10+
"main": "./build/extension.js",
11+
"scripts": {
12+
"vscode:prepublish": "yarn run compile",
13+
"compile": "webpack --mode production",
14+
"compile:tsc": "tsc -p ./",
15+
"webview:dev-vue": "yarn --cwd \"webview-vue\" dev",
16+
"webview:build-vue": "yarn --cwd \"webview-vue\" build",
17+
"webview:dev-react": "yarn --cwd \"webview-react\" dev",
18+
"webview:build-react": "yarn --cwd \"webview-react\" build",
19+
"lint": "eslint src --ext ts",
20+
"watch": "webpack --mode development",
21+
"pretest": "yarn run compile:tsc",
22+
"test:js": "node ./build/test/runTest.js",
23+
"test": "node ./build/test/runTest.js"
24+
},
25+
"engines": {
26+
"vscode": "^1.42.0"
27+
},
28+
"categories": [
29+
"Other"
30+
],
31+
"keywords": [
32+
"yapi",
33+
"typescript",
34+
"generate code",
35+
"json",
36+
"lowcode"
37+
],
38+
"activationEvents": [
39+
"*"
40+
],
41+
"contributes": {
42+
"commands": [
43+
{
44+
"command": "yapi-code.generateCodeByWebview",
45+
"title": "可视化生成代码"
46+
},
47+
{
48+
"command": "yapi-code.generateCode",
49+
"title": "生成代码"
50+
},
51+
{
52+
"command": "lowcode.openDownloadMaterials",
53+
"title": "下载物料"
54+
},
55+
{
56+
"command": "yapi-code.addSnippet",
57+
"title": "添加代码片段"
58+
},
59+
{
60+
"command": "lowcode.quickGenerateBlock",
61+
"title": "快速创建区块"
62+
}
63+
],
64+
"menus": {
65+
"editor/context": [
66+
{
67+
"submenu": "lowcode/editor/context",
68+
"group": "1_lowcode@1"
69+
}
70+
],
71+
"explorer/context": [
72+
{
73+
"submenu": "lowcode/explorer/context",
74+
"group": "2_lowcode@1",
75+
"when": "explorerResourceIsFolder"
76+
}
77+
],
78+
"lowcode/editor/context": [
79+
{
80+
"command": "yapi-code.generateCodeByWebview",
81+
"group": "lowcode@1"
82+
},
83+
{
84+
"command": "yapi-code.generateCode",
85+
"group": "lowcode@2"
86+
},
87+
{
88+
"command": "lowcode.openDownloadMaterials",
89+
"group": "lowcode@3"
90+
},
91+
{
92+
"command": "yapi-code.addSnippet",
93+
"group": "lowcode@4"
94+
}
95+
],
96+
"lowcode/explorer/context": [
97+
{
98+
"command": "lowcode.quickGenerateBlock",
99+
"group": "lowcode@1"
100+
},
101+
{
102+
"command": "yapi-code.generateCodeByWebview",
103+
"group": "lowcode@2"
104+
},
105+
{
106+
"command": "lowcode.openDownloadMaterials",
107+
"group": "lowcode@3"
108+
}
109+
]
110+
},
111+
"submenus": [
112+
{
113+
"id": "lowcode/editor/context",
114+
"label": "Low Code"
115+
},
116+
{
117+
"id": "lowcode/explorer/context",
118+
"label": "Low Code"
119+
}
120+
],
121+
"viewsContainers": {
122+
"activitybar": [
123+
{
124+
"id": "lowcodeApp",
125+
"title": "lowcode",
126+
"icon": "asset/activitybar.svg"
127+
}
128+
]
129+
},
130+
"views": {
131+
"lowcodeApp": [
132+
{
133+
"id": "lowcode.welcome",
134+
"name": "Welcome"
135+
}
136+
]
137+
},
138+
"viewsWelcome": [
139+
{
140+
"view": "lowcode.welcome",
141+
"contents": "[打开文件夹](command:lowcode.openFolderForceNewWindow)\n[创建应用](command:lowcode.openScaffold)\n[设置](command:lowcode.openConfig)\n查看[文档](https://lowcoding.gitee.io)以学习如何在 VS Code 中如何使用 lowcode。"
142+
}
143+
]
144+
},
145+
"devDependencies": {
146+
"@types/copy-paste": "^1.1.30",
147+
"@types/debug": "^4.1.5",
148+
"@types/ejs": "^3.0.4",
149+
"@types/fs-extra": "^9.0.1",
150+
"@types/glob": "^7.1.1",
151+
"@types/mocha": "^7.0.2",
152+
"@types/node": "^13.11.0",
153+
"@types/prettier": "^2.0.2",
154+
"@types/readable-stream": "^2.3.9",
155+
"@types/urijs": "^1.19.9",
156+
"@types/vscode": "1.42.0",
157+
"@typescript-eslint/eslint-plugin": "^4.18.0",
158+
"@typescript-eslint/parser": "^4.18.0",
159+
"eslint": "^6.8.0",
160+
"eslint-config-airbnb-base": "^14.2.1",
161+
"eslint-config-prettier": "^8.3.0",
162+
"eslint-plugin-import": "^2.24.0",
163+
"eslint-plugin-prettier": "^3.3.1",
164+
"glob": "^7.1.6",
165+
"mocha": "^7.1.2",
166+
"prettier": "^2.2.1",
167+
"ts-loader": "^8.0.3",
168+
"typescript": "^4.3.5",
169+
"vscode-test": "^1.3.0",
170+
"webpack": "^4.44.1",
171+
"webpack-cli": "^3.3.12"
172+
},
173+
"dependencies": {
174+
"axios": "^0.19.2",
175+
"copy-paste": "^1.3.0",
176+
"directory-tree": "^2.2.4",
177+
"ejs": "^3.1.3",
178+
"execa": "^4.0.3",
179+
"fs-extra": "^9.0.1",
180+
"generate-schema": "^2.6.0",
181+
"globby": "^11.0.1",
182+
"is-url": "^1.2.4",
183+
"json-schema-to-typescript": "^9.1.1",
184+
"strip-comments": "^2.0.1",
185+
"strip-json-comments": "^3.1.1",
186+
"tar": "^6.0.5",
187+
"typescript-json-schema": "^0.50.1"
188+
}
189189
}

src/genCode/genCodeByJson.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export const genCodeByJson = async (
2121

2222
const templateResult = await window.showQuickPick(
2323
templateList.map((s) => s.name),
24-
{ placeHolder: '请选择模板' },
24+
{ placeHolder: '请选择JSON相关模板' },
2525
);
2626
if (!templateResult) {
2727
return;

0 commit comments

Comments
 (0)