File tree 1 file changed +5
-4
lines changed
src/devtools/views/components
1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -99,11 +99,13 @@ export default {
99
99
},
100
100
openInEditor () {
101
101
const file = this .target .file
102
- const src = ` fetch('/__open-in-editor?file=${ file} ').then(response => {
102
+ // Console display
103
+ const fileName = file .replace (/ \\ / g , ' \\\\ ' )
104
+ const src = ` fetch('/__open-in-editor?file=${ encodeURI (file)} ').then(response => {
103
105
if (response.ok) {
104
- console.log('File ${ file } opened in editor')
106
+ console.log('File ${ fileName } opened in editor')
105
107
} else {
106
- const msg = 'Opening component ${ file } failed'
108
+ const msg = 'Opening component ${ fileName } failed'
107
109
if (__VUE_DEVTOOLS_TOAST__) {
108
110
__VUE_DEVTOOLS_TOAST__(msg, 'error')
109
111
} else {
@@ -127,4 +129,3 @@ export default {
127
129
.title
128
130
white-space nowrap
129
131
</style >
130
-
You can’t perform that action at this time.
0 commit comments