Skip to content

Commit

Permalink
fix: #281
Browse files Browse the repository at this point in the history
  • Loading branch information
YeungHoiChiu committed Jun 14, 2024
1 parent b6b7e8c commit 6ab5735
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 22 deletions.
2 changes: 1 addition & 1 deletion src/views/RemoteEmulator/AndroidRemote.vue
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ defineProps({
const tabWebView = (port, id, transTitle) => {
title.value = transTitle;
isWebView.value = false;
iframeUrl.value = `/chrome/devtools/inspector.html?ws=${agent.value.host}:${agent.value.port}/websockets/webView/${agent.value.secretKey}/${port}/${id}`;
iframeUrl.value = `/chrome_devtools/front_end/inspector.html?ws=${agent.value.host}:${agent.value.port}/websockets/webView/${agent.value.secretKey}/${port}/${id}`;
nextTick(() => {
iFrameHeight.value = document.body.clientHeight - 150;
});
Expand Down
2 changes: 1 addition & 1 deletion src/views/RemoteEmulator/IOSRemote.vue
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ defineProps({
const tabWebView = (port, id, transTitle) => {
title.value = transTitle;
isWebView.value = false;
iframeUrl.value = `/chrome/devtools/inspector.html?ws=${agent.value.host}:${agent.value.port}/websockets/webView/${agent.value.secretKey}/${port}/${id}`;
iframeUrl.value = `/chrome_devtools/front_end/inspector.html?ws=${agent.value.host}:${agent.value.port}/websockets/webView/${agent.value.secretKey}/${port}/${id}`;
nextTick(() => {
iFrameHeight.value = document.body.clientHeight - 180;
});
Expand Down
48 changes: 28 additions & 20 deletions vite.config.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,35 @@
import {defineConfig} from 'vite';
import {join} from 'path';
import { defineConfig } from 'vite';
import { join } from 'path';
import vue from '@vitejs/plugin-vue';

// https://vitejs.dev/config/
export default defineConfig({
plugins: [vue()],
server:{
port: 3002
},
build: {
rollupOptions: {
output: {
manualChunks(id) {
if (id.includes('node_modules')) {
return id.toString().split('node_modules/')[1].split('/')[0].toString();
}
}
}
}
},
resolve: {
alias: {
'@': join(__dirname, 'src'),
optimizeDeps: {
// vite pre-bundle dependency enter file
entries: ['src/**/*'],
},
plugins: [vue()],
server: {
port: 3002,
},
build: {
rollupOptions: {
output: {
manualChunks(id) {
if (id.includes('node_modules')) {
return id
.toString()
.split('node_modules/')[1]
.split('/')[0]
.toString();
}
},
},
},
},
resolve: {
alias: {
'@': join(__dirname, 'src'),
},
},
});

0 comments on commit 6ab5735

Please sign in to comment.