Compare commits
8 Commits
Author | SHA1 | Date |
---|---|---|
|
7bc9959465 | |
|
d06c66ad39 | |
|
78e1b7128a | |
|
342712f219 | |
|
5e1003f95a | |
|
cedf6b613d | |
|
98fdd6a489 | |
|
e23a4bc500 |
|
@ -1,8 +0,0 @@
|
||||||
import Store from 'electron-store'
|
|
||||||
|
|
||||||
const store = new Store()
|
|
||||||
const set = (key, val) => store.set(key, val)
|
|
||||||
|
|
||||||
const get = (key) => store.get(key)
|
|
||||||
|
|
||||||
export default {set, get}
|
|
|
@ -1,58 +0,0 @@
|
||||||
<template>
|
|
||||||
<vc-viewer :shouldAnimate="true" :showCredit="false" :infoBox="false" @ready="onViewerReady">
|
|
||||||
<vc-layer-imagery>
|
|
||||||
<vc-provider-imagery-singletile :url="earth" />
|
|
||||||
</vc-layer-imagery>
|
|
||||||
|
|
||||||
<vc-entity :show="show" :position="position">
|
|
||||||
<vc-graphics-billboard :image="pin" :verticalOrigin="1" />
|
|
||||||
</vc-entity>
|
|
||||||
</vc-viewer>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
|
|
||||||
<script lang="ts" setup>
|
|
||||||
import { reactive, computed } from 'vue'
|
|
||||||
import { getPosition } from '../api/util'
|
|
||||||
import pin from '../assets/pin.png'
|
|
||||||
import earth from '../assets/earth.jpg'
|
|
||||||
|
|
||||||
const position = reactive({ lng: NaN, lat: NaN })
|
|
||||||
const show = computed(() => {
|
|
||||||
const { lng, lat } = position
|
|
||||||
|
|
||||||
if (isNaN(lng) || lng > 180 || lng < -180) return false
|
|
||||||
if (isNaN(lat) || lat > 90 || lat < -90 ) return false
|
|
||||||
|
|
||||||
return true
|
|
||||||
})
|
|
||||||
|
|
||||||
// 设置地球自转动画效果
|
|
||||||
const onViewerReady = ({ Cesium, viewer }) => {
|
|
||||||
const { JulianDate, Cartesian3 } = Cesium
|
|
||||||
const { clock, scene } = viewer
|
|
||||||
|
|
||||||
let prev = clock.currentTime
|
|
||||||
clock.onTick.addEventListener(() => {
|
|
||||||
const current = clock.currentTime
|
|
||||||
|
|
||||||
const interval = JulianDate.toDate(current) - JulianDate.toDate(prev)
|
|
||||||
prev = current
|
|
||||||
|
|
||||||
scene.camera.rotate(
|
|
||||||
Cartesian3.UNIT_Z,
|
|
||||||
(Math.PI / (24 * 60 * 60)) * interval * 1,
|
|
||||||
);
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
const update = (nmea) => {
|
|
||||||
const newPosition = getPosition(nmea)
|
|
||||||
if (!newPosition) return
|
|
||||||
|
|
||||||
Object.assign(position, newPosition)
|
|
||||||
}
|
|
||||||
|
|
||||||
defineExpose({ update })
|
|
||||||
</script>
|
|
|
@ -1,15 +0,0 @@
|
||||||
import { createApp } from 'vue'
|
|
||||||
import App from './App.vue'
|
|
||||||
|
|
||||||
import 'vue-cesium/dist/index.css'
|
|
||||||
import { VcViewer, VcEntity, VcLayerImagery, VcProviderImagerySingletile, VcGraphicsBillboard } from 'vue-cesium'
|
|
||||||
|
|
||||||
import './main.css'
|
|
||||||
|
|
||||||
const cesiumPath = (process.env.NODE_ENV === 'development' ? './node_modules/cesium/Build/Cesium/Cesium.js': './Cesium/Cesium.js')
|
|
||||||
|
|
||||||
const app = createApp(App)
|
|
||||||
// 局部引入VueCesium
|
|
||||||
app.use(VcViewer).use(VcEntity).use(VcLayerImagery).use(VcProviderImagerySingletile).use(VcGraphicsBillboard)
|
|
||||||
app.config.globalProperties.$VueCesium = { cesiumPath }
|
|
||||||
app.mount('#app')
|
|
File diff suppressed because it is too large
Load Diff
|
@ -2,41 +2,47 @@
|
||||||
"name": "beidou-satellite-data-monitor",
|
"name": "beidou-satellite-data-monitor",
|
||||||
"description": "beidou-satellite-data-monitor",
|
"description": "beidou-satellite-data-monitor",
|
||||||
"author": "hwasmart",
|
"author": "hwasmart",
|
||||||
"version": "5.5.9",
|
"version": "5.6.0",
|
||||||
"main": "dist/main/app.js",
|
"main": "dist/main/app.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"install": "electron-rebuild",
|
"dev": "vite --port=3000",
|
||||||
"dev": "vite",
|
|
||||||
"build": "vite build",
|
"build": "vite build",
|
||||||
"serve": "vite preview",
|
"serve": "vite preview",
|
||||||
"electron:dev": "cross-env NODE_ENV=development electron index.js",
|
"electron:dev": "cross-env NODE_ENV=development electron index.js",
|
||||||
"electron:build": "rimraf dist && vite build && tsc -p tsconfig.electron.json && electron-builder"
|
"electron:build": "rimraf dist && vite build && tsc -p tsconfig.electron.json && electron-builder"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@serialport/bindings": "^9.2.9",
|
||||||
|
"@serialport/parser-inter-byte-timeout": "^12.0.0",
|
||||||
"cesium": "^1.88.0",
|
"cesium": "^1.88.0",
|
||||||
|
"conf": "^13.0.1",
|
||||||
"echarts": "^5.1.0",
|
"echarts": "^5.1.0",
|
||||||
"electron-store": "^8.0.0",
|
"electron-store": "^8.0.0",
|
||||||
"nmea": "http://git.hwasmart.com/bd_group/node-nmea.git",
|
"nmea": "http://git.hwasmart.com/bd_group/node-nmea.git",
|
||||||
"serialport": "10.0.0",
|
"serialport": "^12.0.0",
|
||||||
|
"through": "^2.3.8",
|
||||||
"vue": "^3.2.26",
|
"vue": "^3.2.26",
|
||||||
"vue-cesium": "3.0.2-beta.13",
|
"vue-cesium": "^v3.2.8",
|
||||||
"vue-echarts": "^6.0.0-rc.4"
|
"vue-echarts": "^6.0.0-rc.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@types/node": "^22.5.4",
|
||||||
"@vitejs/plugin-vue": "^1.1.5",
|
"@vitejs/plugin-vue": "^1.1.5",
|
||||||
"@vue/compiler-sfc": "^3.2.26",
|
"@vue/compiler-sfc": "^3.2.26",
|
||||||
"autoprefixer": "^10.2.5",
|
"autoprefixer": "^10.2.5",
|
||||||
"cross-env": "^7.0.3",
|
"cross-env": "^7.0.3",
|
||||||
"electron": "^13.6.3",
|
"electron": "^19.0.3",
|
||||||
"electron-builder": "^22.10.5",
|
"electron-builder": "^25.0.5",
|
||||||
"electron-rebuild": "2.3.5",
|
"electron-rebuild": "2.3.5",
|
||||||
"postcss": "^8.2.10",
|
"postcss": "^8.2.10",
|
||||||
"rimraf": "^3.0.2",
|
"rimraf": "^3.0.2",
|
||||||
"rollup-plugin-copy": "^3.4.0",
|
"rollup-plugin-copy": "^3.4.0",
|
||||||
"tailwindcss": "^2.1.1",
|
"tailwindcss": "^2.1.1",
|
||||||
"ts-node": "^9.1.1",
|
"ts-node": "^9.1.1",
|
||||||
"typescript": "^4.2.3",
|
"typescript": "^5.5.4",
|
||||||
"vite": "^2.0.5"
|
"vite": "^2.0.5",
|
||||||
|
"vite-plugin-electron": "^0.28.7",
|
||||||
|
"vite-plugin-electron-renderer": "^0.14.5"
|
||||||
},
|
},
|
||||||
"build": {
|
"build": {
|
||||||
"appId": "hwasmart.id",
|
"appId": "hwasmart.id",
|
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 72 KiB |
|
@ -1,16 +1,16 @@
|
||||||
import { app, screen, globalShortcut, BrowserWindow, ipcMain, dialog } from 'electron'
|
import { app, screen, globalShortcut, BrowserWindow, ipcMain, dialog } from 'electron'
|
||||||
import { join } from "path"
|
import { join } from "path"
|
||||||
import config from './config'
|
import config from './config.js'
|
||||||
import './load-serialport'
|
import './load-serialport'
|
||||||
import { keyword } from './KeyWord'
|
import { keyword } from './KeyWord'
|
||||||
|
|
||||||
const child_process = require('child_process')
|
import child_process from 'child_process'
|
||||||
const crypto = require('crypto')
|
import crypto from 'crypto'
|
||||||
|
|
||||||
function queryPass(passPath: string, passValue: string) {
|
function queryPass(passPath: string, passValue: string) {
|
||||||
return new Promise(function (resolve, reject) {
|
return new Promise(function (resolve, reject) {
|
||||||
try {
|
try {
|
||||||
child_process.exec(`reg query ${passPath} /v ${passValue}`, (error: Error, stdout: string, stderr: string) => {
|
child_process.exec(`reg query ${passPath} /v ${passValue}`, (error: Error | null, stdout: string, stderr: string) => {
|
||||||
if (error) {
|
if (error) {
|
||||||
reject(error)
|
reject(error)
|
||||||
return
|
return
|
||||||
|
@ -26,7 +26,7 @@ function queryPass(passPath: string, passValue: string) {
|
||||||
function queryKey(keyPath: string, keyValue: string) {
|
function queryKey(keyPath: string, keyValue: string) {
|
||||||
return new Promise(function (resolve, reject) {
|
return new Promise(function (resolve, reject) {
|
||||||
try {
|
try {
|
||||||
child_process.exec(`reg query ${keyPath} /v ${keyValue}`, (error: Error, stdout: string, stderr: string) => {
|
child_process.exec(`reg query ${keyPath} /v ${keyValue}`, (error: Error | null, stdout: string, stderr: string) => {
|
||||||
if (error) {
|
if (error) {
|
||||||
reject(error)
|
reject(error)
|
||||||
return
|
return
|
||||||
|
@ -121,65 +121,41 @@ const getDisplayOrigin = (display: any) => {
|
||||||
return origin
|
return origin
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var windows:Array<BrowserWindow> = [];
|
||||||
|
|
||||||
function createWindow(option: any, url: any) {
|
function createWindow(option: any, url: any) {
|
||||||
const win = new BrowserWindow(option)
|
const win = new BrowserWindow(option)
|
||||||
|
|
||||||
if (URl_REGEX.test(url)) {
|
if (URl_REGEX.test(url)) {
|
||||||
win.loadURL(url)
|
win.loadURL(url)
|
||||||
} else {
|
} else {
|
||||||
win.loadFile(url)
|
win.loadFile(url)
|
||||||
}
|
}
|
||||||
|
if(process.env.NODE_ENV === 'development') win.webContents.openDevTools()
|
||||||
|
windows.push(win);
|
||||||
|
}
|
||||||
|
|
||||||
const isWindows = process.platform === 'win32';
|
ipcMain.on('CLOSE', (event) => {
|
||||||
let needsFocusFix = false;
|
const res = dialog.showMessageBox({
|
||||||
let triggeringProgrammaticBlur = false;
|
type: 'warning',
|
||||||
|
title: '警告',
|
||||||
//弹出警报窗口后 input获取不到焦点
|
message: '确定要关闭软件吗?',
|
||||||
win.on('blur', (event: any) => {
|
detail: '关闭软件',
|
||||||
if(!triggeringProgrammaticBlur) {
|
cancelId: 1, // 按esc默认点击索引按钮
|
||||||
needsFocusFix = true;
|
defaultId: 0, // 默认高亮的按钮下标
|
||||||
}
|
buttons: ['确认', '取消'], // 按钮按索引从右往左排序
|
||||||
})
|
|
||||||
|
|
||||||
win.on('focus', (event: any) => {
|
|
||||||
if(isWindows && needsFocusFix) {
|
|
||||||
needsFocusFix = false;
|
|
||||||
triggeringProgrammaticBlur = true;
|
|
||||||
//弹出弹窗后重新聚焦导致windows任务栏显示,重新隐藏底部windows任务栏
|
|
||||||
win.minimize(); //最小化函数
|
|
||||||
win.restore(); //取消最小化函数(从最小化窗口还原函数)
|
|
||||||
setTimeout(function () {
|
|
||||||
win.blur(); //失去焦点函数
|
|
||||||
win.focus(); //获取焦点函数
|
|
||||||
setTimeout(function () {
|
|
||||||
triggeringProgrammaticBlur = false;
|
|
||||||
}, 100);
|
|
||||||
}, 100);
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
if(process.env.NODE_ENV === 'development') win.webContents.openDevTools()
|
res.then((data)=>{
|
||||||
|
if(data.response == 0){
|
||||||
ipcMain.on('CLOSE', (event) => {
|
windows.forEach((key:BrowserWindow) => {
|
||||||
const res = dialog.showMessageBox({
|
key.close();
|
||||||
type: 'warning',
|
});
|
||||||
title: '警告',
|
windows = [];
|
||||||
message: '确定要关闭软件吗?',
|
}else{
|
||||||
detail: '关闭软件',
|
console.log('not close software')
|
||||||
cancelId: 1, // 按esc默认点击索引按钮
|
}
|
||||||
defaultId: 0, // 默认高亮的按钮下标
|
|
||||||
buttons: ['确认', '取消'], // 按钮按索引从右往左排序
|
|
||||||
})
|
|
||||||
|
|
||||||
res.then((data)=>{
|
|
||||||
if(data.response == 0){
|
|
||||||
win.close()
|
|
||||||
}else{
|
|
||||||
console.log('not close software')
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
}
|
})
|
||||||
|
|
||||||
app.whenReady().then(() => {
|
app.whenReady().then(() => {
|
||||||
launch()
|
launch()
|
|
@ -0,0 +1,10 @@
|
||||||
|
// import Store from 'electron-store'
|
||||||
|
const Store = require('electron-store')
|
||||||
|
|
||||||
|
const store = new Store()
|
||||||
|
const set = (key, val) => store.set(key, val)
|
||||||
|
|
||||||
|
const get = (key) => store.get(key)
|
||||||
|
|
||||||
|
// export default {set, get}
|
||||||
|
module.exports = { set, get }
|
|
@ -1,6 +1,6 @@
|
||||||
import SerialPort from 'serialport'
|
import { SerialPort } from 'serialport'
|
||||||
import InterByteTimeout from '@serialport/parser-inter-byte-timeout'
|
import { InterByteTimeoutParser } from '@serialport/parser-inter-byte-timeout'
|
||||||
import config from './config'
|
import config from './config.js'
|
||||||
import sendMsg from './ipcRendererManager'
|
import sendMsg from './ipcRendererManager'
|
||||||
import NMEAHandler from './api/NMEAHandler'
|
import NMEAHandler from './api/NMEAHandler'
|
||||||
|
|
||||||
|
@ -10,7 +10,6 @@ const getSerialPortConstructorArguments = (ports) => {
|
||||||
ports = ports.filter((port) => port.path != 'COM1')
|
ports = ports.filter((port) => port.path != 'COM1')
|
||||||
if (ports.length == 0) return
|
if (ports.length == 0) return
|
||||||
|
|
||||||
// console.log(ports, '=====================')
|
|
||||||
const serialport = config.get('serialport')
|
const serialport = config.get('serialport')
|
||||||
const path = ( serialport && serialport.path ) ? serialport.path : ports[0].path
|
const path = ( serialport && serialport.path ) ? serialport.path : ports[0].path
|
||||||
const baudRate = ( serialport && serialport.baudRate ) ? serialport.baudRate : DEFAULT_BAUDRATE
|
const baudRate = ( serialport && serialport.baudRate ) ? serialport.baudRate : DEFAULT_BAUDRATE
|
||||||
|
@ -27,9 +26,8 @@ const openSerialport = (ports) => {
|
||||||
|
|
||||||
const { path, baudRate } = constructorArguments
|
const { path, baudRate } = constructorArguments
|
||||||
|
|
||||||
// console.log(path, baudRate, '++++++++++++++===');
|
const serialPort = new SerialPort({ path, baudRate })
|
||||||
const serialPort = new SerialPort(path, { baudRate })
|
const parser = serialPort.pipe(new InterByteTimeoutParser({interval: 300}))
|
||||||
const parser = serialPort.pipe(new InterByteTimeout({interval: 300}))
|
|
||||||
|
|
||||||
NMEAHandler.on('received' , (nmeaStr) => {
|
NMEAHandler.on('received' , (nmeaStr) => {
|
||||||
sendMsg('NMEA_RECEIVED', nmeaStr)
|
sendMsg('NMEA_RECEIVED', nmeaStr)
|
|
@ -15,6 +15,9 @@
|
||||||
<div class="text-center w-1/2 ml-auto">
|
<div class="text-center w-1/2 ml-auto">
|
||||||
<BaseInfoView ref="baseInfoViewInstance" />
|
<BaseInfoView ref="baseInfoViewInstance" />
|
||||||
</div>
|
</div>
|
||||||
|
<div class="text-white fixed bottom-0 right-0">
|
||||||
|
北斗卫星数据监测展示互动系统V1.0
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.3 MiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
|
@ -6,26 +6,10 @@
|
||||||
<div class="label">经 度:</div>
|
<div class="label">经 度:</div>
|
||||||
<div class="content">{{ baseInfo.longitude ? baseInfo.longitude : '' }}</div>
|
<div class="content">{{ baseInfo.longitude ? baseInfo.longitude : '' }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
<div class="label">经度度分:</div>
|
|
||||||
<div class="content">{{ baseInfo.longitude ? longitudeD + ' ' + longitudeM : '' }}</div>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<div class="label">经度分秒:</div>
|
|
||||||
<div class="content">{{ baseInfo.longitude ? longitudeD + ' ' + longitudeM + ' ' + longitudeS : '' }}</div>
|
|
||||||
</div>
|
|
||||||
<div>
|
<div>
|
||||||
<div class="label">纬 度:</div>
|
<div class="label">纬 度:</div>
|
||||||
<div class="content">{{ baseInfo.latitude ? baseInfo.latitude : '' }}</div>
|
<div class="content">{{ baseInfo.latitude ? baseInfo.latitude : '' }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
<div class="label">纬度度分:</div>
|
|
||||||
<div class="content">{{ baseInfo.latitude ? latitudeD + ' ' + latitudeM : '' }}</div>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<div class="label">纬度分秒:</div>
|
|
||||||
<div class="content">{{ baseInfo.latitude ? latitudeD + ' ' + latitudeM + ' ' + latitudeS : '' }}</div>
|
|
||||||
</div>
|
|
||||||
<div>
|
<div>
|
||||||
<div class="label">海 拔:</div>
|
<div class="label">海 拔:</div>
|
||||||
<div class="content">{{ baseInfo.altitude }}</div>
|
<div class="content">{{ baseInfo.altitude }}</div>
|
|
@ -0,0 +1,56 @@
|
||||||
|
<template>
|
||||||
|
<vc-config-provider :cesiumPath="cesiumPath">
|
||||||
|
<vc-viewer :shouldAnimate="true" :showCredit="false" :infoBox="false" @ready="onViewerReady">
|
||||||
|
<vc-layer-imagery>
|
||||||
|
<vc-imagery-provider-singletile :url="earth" />
|
||||||
|
</vc-layer-imagery>
|
||||||
|
|
||||||
|
<vc-entity :show="show" :position="position">
|
||||||
|
<vc-graphics-billboard :image="pin" :verticalOrigin="1" />
|
||||||
|
</vc-entity>
|
||||||
|
</vc-viewer>
|
||||||
|
</vc-config-provider>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { reactive, computed } from "vue";
|
||||||
|
import { getPosition } from "../api/util";
|
||||||
|
import pin from "../assets/pin.png";
|
||||||
|
import earth from "../assets/earth.jpg";
|
||||||
|
|
||||||
|
const cesiumPath = (process.env.NODE_ENV === 'development' ? './node_modules/cesium/Build/Cesium/Cesium.js': './Cesium/Cesium.js')
|
||||||
|
const position = reactive({ lng: NaN, lat: NaN });
|
||||||
|
const show = computed(() => {
|
||||||
|
const { lng, lat } = position;
|
||||||
|
|
||||||
|
if (isNaN(lng) || lng > 180 || lng < -180) return false;
|
||||||
|
if (isNaN(lat) || lat > 90 || lat < -90) return false;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
|
||||||
|
// 设置地球自转动画效果
|
||||||
|
const onViewerReady = ({ Cesium, viewer }) => {
|
||||||
|
const { JulianDate, Cartesian3 } = Cesium;
|
||||||
|
const { clock, scene } = viewer;
|
||||||
|
|
||||||
|
let prev = clock.currentTime;
|
||||||
|
clock.onTick.addEventListener(() => {
|
||||||
|
const current = clock.currentTime;
|
||||||
|
|
||||||
|
const interval = JulianDate.toDate(current) - JulianDate.toDate(prev);
|
||||||
|
prev = current;
|
||||||
|
|
||||||
|
scene.camera.rotate(Cartesian3.UNIT_Z, (Math.PI / (24 * 60 * 60)) * interval * 1);
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
const update = (nmea) => {
|
||||||
|
const newPosition = getPosition(nmea);
|
||||||
|
if (!newPosition) return;
|
||||||
|
|
||||||
|
Object.assign(position, newPosition);
|
||||||
|
};
|
||||||
|
|
||||||
|
defineExpose({ update });
|
||||||
|
</script>
|
|
@ -47,7 +47,7 @@ const option = reactive({
|
||||||
inverse: true,
|
inverse: true,
|
||||||
axisLine: {show: false},
|
axisLine: {show: false},
|
||||||
axisTick: {show: false},
|
axisTick: {show: false},
|
||||||
axisLabel: {color: 'white'}
|
axisLabel: {color: 'white', fontSize: '12'},
|
||||||
},
|
},
|
||||||
series: [{
|
series: [{
|
||||||
type: 'bar',
|
type: 'bar',
|
|
@ -0,0 +1,11 @@
|
||||||
|
import { createApp } from 'vue'
|
||||||
|
import App from './App.vue'
|
||||||
|
|
||||||
|
import 'vue-cesium/dist/index.css'
|
||||||
|
import { VcConfigProvider, VcViewer, VcEntity, VcLayerImagery, VcImageryProviderSingletile, VcGraphicsBillboard } from 'vue-cesium'
|
||||||
|
|
||||||
|
import './main.css'
|
||||||
|
|
||||||
|
const app = createApp(App)
|
||||||
|
app.use(VcConfigProvider).use(VcViewer).use(VcEntity).use(VcLayerImagery).use(VcImageryProviderSingletile).use(VcGraphicsBillboard)
|
||||||
|
app.mount('#app')
|
|
@ -7,10 +7,12 @@
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
"allowJs": true,
|
"allowJs": true,
|
||||||
"outDir": "dist/main"
|
"outDir": "dist/main",
|
||||||
|
"forceConsistentCasingInFileNames": true,
|
||||||
|
"skipLibCheck": true
|
||||||
},
|
},
|
||||||
"include": [
|
"include": [
|
||||||
"src/main/app.ts",
|
"src/main/app.ts",
|
||||||
"src/main/preload.js",
|
"src/main/preload.js",
|
||||||
]
|
]
|
||||||
}
|
}
|
|
@ -10,8 +10,12 @@
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
"lib": ["esnext", "dom"],
|
"lib": ["esnext", "dom"],
|
||||||
"types": ["vite/client"],
|
"types": ["vite/client"],
|
||||||
// ---------------------- //
|
"noImplicitAny": false,
|
||||||
"noImplicitAny": false
|
"useDefineForClassFields": true,
|
||||||
|
"noEmit": true,
|
||||||
|
"isolatedModules": true,
|
||||||
|
"forceConsistentCasingInFileNames": true,
|
||||||
|
"skipLibCheck": true
|
||||||
},
|
},
|
||||||
"include": ["src/render/**/*.ts", "src/render/**/*.d.ts", "src/render/**/*.tsx", "src/render/**/*.vue"],
|
"include": ["src/render/**/*.ts", "src/render/**/*.d.ts", "src/render/**/*.tsx", "src/render/**/*.vue"],
|
||||||
"exclude": ["src/app.ts"]
|
"exclude": ["src/app.ts"]
|
|
@ -11,11 +11,14 @@ const publicDir = join(__dirname, 'public')
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
publicDir,
|
publicDir,
|
||||||
base: './',
|
base: './',
|
||||||
plugins: [vue(),copy({
|
plugins: [
|
||||||
targets: [
|
vue(),
|
||||||
{ src: './node_modules/cesium/Build/Cesium', dest: publicDir }, //编译时,执行Cesium库的拷贝
|
copy({
|
||||||
]
|
targets: [
|
||||||
})],
|
{ src: './node_modules/cesium/Build/Cesium', dest: publicDir }, //编译时,执行Cesium库的拷贝
|
||||||
|
]
|
||||||
|
})
|
||||||
|
],
|
||||||
build: {
|
build: {
|
||||||
outDir,
|
outDir,
|
||||||
emptyOutDir: true,
|
emptyOutDir: true,
|
Loading…
Reference in New Issue