@@ -91,7 +91,30 @@ To check if your setup is correct, you can try out Benedikt’s
91
91
[ Hello World] [ hello-world ] demo project. Just follow the steps outlined in the
92
92
` README.md ` there.
93
93
94
- ## Vite
94
+ ### Vanilla Web App
95
+
96
+ To use the Automatic Workspace Folders feature with a vanilla web app, all you
97
+ need to do is to create a ` .well-known/appspecific ` folder and place a
98
+ ` com.chrome.devtools.json ` file there. Let's assume you're using [ serve] [ serve ]
99
+ and you're directly serving the artifacts for your project from its source
100
+ directory in ` /Users/foo/bar ` , then you could can accomplish the setup via:
101
+
102
+ ```
103
+ cd /Users/foo/bar
104
+ mkdir -p .well-known/appspecific
105
+ echo "{\"workspace\":{\"root\":\"${PWD}\",\"uuid\":\"`npx --package uuid uuid v1`\"}}" > .well-known/appspecific/com.chrome.devtools.json
106
+ npx serve
107
+ ```
108
+
109
+ If everything is working correctly, you'll see requests from DevTools to
110
+ ` /.well-known/appspecific/com.chrome.devtools.json ` in your ` serve ` output, e.g.:
111
+
112
+ ```
113
+ HTTP 4/9/2025 9:21:32 AM ::1 GET /.well-known/appspecific/com.chrome.devtools.json
114
+ HTTP 4/9/2025 9:21:32 AM ::1 Returned 304 in 2 ms
115
+ ```
116
+
117
+ ### Vite
95
118
96
119
There's also a proof-of-concept plugin for [ vite] ( http://vite.dev ) available at
97
120
[ ChromeDevTools/vite-plugin-devtools-json] [ vite-plugin ] , which you can easily
@@ -101,7 +124,8 @@ add to your existing project.
101
124
[ design-doc ] : http://go/chrome-devtools:automatic-workspace-folders-design
102
125
[ demo ] : http://go/chrome-devtools:automatic-workspace-folders-demo
103
126
[ workspace-doc ] : https://developer.chrome.com/docs/devtools/workspaces
104
- [ workspaces -announcement] : https://developer.chrome.com/blog/new-in-devtools-63#workspaces
127
+ [ workspace -announcement] : https://developer.chrome.com/blog/new-in-devtools-63#workspaces
105
128
[ design-doc-json ] : https://goo.gle/devtools-json-design
106
129
[ hello-world ] : https://github.com/bmeurer/automatic-workspace-folders-hello-world
130
+ [ serve ] : https://www.npmjs.com/package/serve
107
131
[ vite-plugin ] : https://github.com/ChromeDevTools/vite-plugin-devtools-json
0 commit comments