-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathpackage.json
More file actions
346 lines (346 loc) · 11.1 KB
/
Copy pathpackage.json
File metadata and controls
346 lines (346 loc) · 11.1 KB
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
{
"name": "django-orm-lens",
"displayName": "Django ORM Lens",
"description": "Autocomplete Django model fields and lookups inside .filter(), and see your entire schema in your editor. Live sidebar, ER diagrams, impact analysis, blast radius and schema drift. Static analysis - no DB, no Django boot. Free and MIT, no Pro tier.",
"version": "0.19.0",
"preview": false,
"galleryBanner": {
"color": "#0c4b33",
"theme": "dark"
},
"qna": "marketplace",
"sponsor": {
"url": "https://github.com/sponsors/FROWNINGdev"
},
"publisher": "frowningdev",
"license": "MIT",
"icon": "media/icon.png",
"repository": {
"type": "git",
"url": "https://github.com/FROWNINGdev/django-orm-lens.git"
},
"bugs": {
"url": "https://github.com/FROWNINGdev/django-orm-lens/issues"
},
"homepage": "https://github.com/FROWNINGdev/django-orm-lens#readme",
"engines": {
"vscode": "^1.85.0"
},
"categories": [
"Visualization",
"Programming Languages",
"AI",
"Other"
],
"keywords": [
"django",
"python",
"orm",
"models",
"er diagram",
"erd",
"entity relationship",
"database",
"database schema",
"schema",
"schema visualizer",
"model explorer",
"foreign key",
"relations",
"relationships",
"django-rest-framework",
"drf",
"postgres",
"postgresql",
"static analysis",
"n+1",
"query optimization",
"mcp",
"ai agent",
"cursor",
"vscodium",
"sidebar",
"navigation",
"migration",
"free",
"open source",
"code review",
"pull request",
"schema drift",
"impact analysis",
"blast radius",
"autocomplete",
"intellisense",
"completion",
"queryset",
"filter",
"lookup"
],
"activationEvents": [
"onStartupFinished",
"workspaceContains:**/manage.py",
"workspaceContains:**/models.py"
],
"main": "./out/extension.js",
"contributes": {
"viewsContainers": {
"activitybar": [
{
"id": "djangoOrmLens",
"title": "Django ORM Lens",
"icon": "media/activitybar.svg"
}
]
},
"views": {
"djangoOrmLens": [
{
"id": "djangoOrmLens.models",
"name": "Models",
"icon": "media/activitybar.svg",
"contextualTitle": "Django Models"
}
]
},
"viewsWelcome": [
{
"view": "djangoOrmLens.models",
"when": "workbenchState == empty",
"contents": "**Open a folder to get started.**\n\nDjango ORM Lens indexes every `models.py` in your project and gives you a live schema tree, an ER diagram, hover cards, and inline QuickFixes for common ORM anti-patterns.\n\n[Open Folder](command:vscode.openFolder)\n\n[Documentation](https://github.com/FROWNINGdev/django-orm-lens#readme)"
},
{
"view": "djangoOrmLens.models",
"when": "workbenchState != empty && !djangoOrmLens.scanCompleted",
"contents": "**Scanning your workspace…**\n\nDjango ORM Lens is walking your project for `models.py` files. This usually takes under a second.\n\nIf the scan doesn't finish, click Refresh below.\n\n[Refresh scan](command:djangoOrmLens.refresh)"
},
{
"view": "djangoOrmLens.models",
"when": "workbenchState != empty && djangoOrmLens.scanCompleted",
"contents": "**No Django models found in this workspace.**\n\nDjango ORM Lens scans for `models.py` files and split `models/` package directories, skipping `migrations/`, `venv/`, and `node_modules/` by default.\n\n[Refresh scan](command:djangoOrmLens.refresh)\n\n[Adjust excluded paths](command:workbench.action.openSettings?%22djangoOrmLens.excludeGlobs%22)\n\n[Documentation](https://github.com/FROWNINGdev/django-orm-lens#readme)"
}
],
"commands": [
{
"command": "djangoOrmLens.refresh",
"title": "Django ORM Lens: Refresh",
"icon": "$(refresh)"
},
{
"command": "djangoOrmLens.showGraph",
"title": "Django ORM Lens: Show ER Diagram",
"icon": "$(type-hierarchy)"
},
{
"command": "djangoOrmLens.jumpToModel",
"title": "Django ORM Lens: Jump to Model"
},
{
"command": "djangoOrmLens.filter",
"title": "Django ORM Lens: Filter Models",
"icon": "$(filter)"
},
{
"command": "djangoOrmLens.clearFilter",
"title": "Django ORM Lens: Clear Filter",
"icon": "$(clear-all)"
},
{
"command": "djangoOrmLens.findReverseRefs",
"title": "Django ORM Lens: Find Reverse References",
"icon": "$(references)"
},
{
"command": "djangoOrmLens.generateFactory",
"title": "Django ORM Lens: Generate factory_boy Factory",
"icon": "$(beaker)"
},
{
"command": "djangoOrmLens.showDiff",
"title": "Django ORM Lens: Schema Diff (Time-Travel)",
"icon": "$(diff)"
},
{
"command": "djangoOrmLens.findImpact",
"title": "Django ORM Lens: Find Impact (What Uses This?)",
"icon": "$(search)"
},
{
"command": "djangoOrmLens.buildQuery",
"title": "Django ORM Lens: Build Query (Insert Snippet)",
"icon": "$(zap)"
}
],
"menus": {
"view/title": [
{
"command": "djangoOrmLens.filter",
"when": "view == djangoOrmLens.models",
"group": "navigation@1"
},
{
"command": "djangoOrmLens.clearFilter",
"when": "view == djangoOrmLens.models",
"group": "navigation@2"
},
{
"command": "djangoOrmLens.refresh",
"when": "view == djangoOrmLens.models",
"group": "navigation@3"
},
{
"command": "djangoOrmLens.showGraph",
"when": "view == djangoOrmLens.models",
"group": "navigation@4"
}
],
"view/item/context": [
{
"command": "djangoOrmLens.findReverseRefs",
"when": "view == djangoOrmLens.models && viewItem == djangoOrmLensModel",
"group": "navigation@1"
},
{
"command": "djangoOrmLens.generateFactory",
"when": "view == djangoOrmLens.models && viewItem == djangoOrmLensModel",
"group": "navigation@2"
},
{
"command": "djangoOrmLens.findImpact",
"when": "view == djangoOrmLens.models && viewItem == djangoOrmLensModel",
"group": "navigation@3"
},
{
"command": "djangoOrmLens.findImpact",
"when": "view == djangoOrmLens.models && viewItem =~ /^field/",
"group": "navigation@1"
},
{
"command": "djangoOrmLens.buildQuery",
"when": "view == djangoOrmLens.models && viewItem == djangoOrmLensModel",
"group": "navigation@4"
},
{
"command": "djangoOrmLens.buildQuery",
"when": "view == djangoOrmLens.models && viewItem =~ /^field/",
"group": "navigation@2"
}
]
},
"configuration": {
"title": "Django ORM Lens",
"properties": {
"djangoOrmLens.excludeGlobs": {
"type": "array",
"default": [
"**/migrations/**",
"**/node_modules/**",
"**/venv/**",
"**/.venv/**",
"**/env/**"
],
"description": "Glob patterns to exclude when scanning for models.py"
},
"djangoOrmLens.autoRefresh": {
"type": "boolean",
"default": true,
"description": "Automatically refresh when models.py files change"
},
"djangoOrmLens.diagramTheme": {
"type": "string",
"default": "auto",
"enum": [
"auto",
"default",
"dark",
"forest",
"neutral"
],
"enumDescriptions": [
"Match the current VS Code color theme (dark or light)",
"Mermaid's default light palette",
"High-contrast dark palette",
"Muted green palette",
"Grayscale palette"
],
"description": "Color theme for the ER diagram webview"
},
"djangoOrmLens.showCodeLens": {
"type": "boolean",
"default": true,
"description": "Show a CodeLens above each Django model class with field/relation counts and an 'Open ER diagram' action"
},
"djangoOrmLens.codeFixes.enabled": {
"type": "boolean",
"default": true,
"description": "Show inline QuickFix diagnostics for Django ORM anti-patterns (DOL001-DOL032). Disable to silence the whole rule set."
},
"djangoOrmLens.completions.enabled": {
"type": "boolean",
"default": true,
"description": "Complete model field names and lookups inside Post.objects.filter(...) and its siblings, traversing ForeignKey edges for author__name paths. Disable if another extension already owns Python completion here."
},
"djangoOrmLens.rules": {
"type": "object",
"default": {},
"description": "Per-rule severity override. Keys are rule codes (DOL001, DOL011, ...), values are 'off' | 'hint' | 'info' | 'warning' | 'error'. Rules not listed use their default severity.",
"patternProperties": {
"^DOL[0-9]+$": {
"type": "string",
"enum": [
"off",
"hint",
"info",
"warning",
"error"
]
}
},
"additionalProperties": false
},
"djangoOrmLens.rulesSelect": {
"type": "array",
"default": [],
"items": {
"type": "string"
},
"description": "Ruff-style select. If non-empty, only rules matching one of these codes/prefixes run. Example: ['DOL0'] to run only queryset+model rules."
},
"djangoOrmLens.rulesIgnore": {
"type": "array",
"default": [],
"items": {
"type": "string"
},
"description": "Ruff-style ignore. Rules whose code matches any prefix here are skipped. Example: ['DOL007'] to silence just the N+1 heuristic."
}
}
}
},
"scripts": {
"vscode:prepublish": "npm run build",
"build": "npm run build:extension && npm run build:webview",
"build:extension": "tsc -p ./",
"build:webview": "esbuild src/webview/graph.tsx --bundle --minify --outfile=media/webview/graph.js --format=iife --loader:.css=text --target=es2020 --define:process.env.NODE_ENV=\\\"production\\\"",
"test": "npm run build && node --test",
"watch": "tsc -watch -p ./",
"package": "vsce package",
"publish": "vsce publish"
},
"devDependencies": {
"@types/node": "^26.5.1",
"@types/react": "^19.2.18",
"@types/react-dom": "^19.3.0",
"@types/vscode": "^1.85.0",
"@vscode/vsce": "^4.0.0",
"esbuild": "^0.28.2",
"sharp": "^0.35.4",
"typescript": "^5.4.0"
},
"dependencies": {
"@xyflow/react": "^12.11.6",
"elkjs": "^0.12.0",
"html-to-image": "^1.11.13",
"react": "^19.2.8",
"react-dom": "^19.3.0"
}
}