Change port for development
This commit is contained in:
parent
b9bb4a89a0
commit
5ff2b02d48
3 changed files with 20 additions and 13 deletions
|
@ -1,2 +1,10 @@
|
|||
import { defineConfig } from 'astro/config'
|
||||
export default defineConfig({srcDir: './astro',outDir: './app'})
|
||||
export default defineConfig({
|
||||
srcDir: './astro',
|
||||
outDir: './app',
|
||||
compressHTML: true,
|
||||
server: {
|
||||
host: false,
|
||||
port: 1567
|
||||
}
|
||||
})
|
|
@ -1,7 +1,6 @@
|
|||
const {BrowserWindow} = require('electron')
|
||||
const glasstron = require('glasstron-clarity') // By SudoVanilla
|
||||
const path = require('path')
|
||||
const {TitlebarRespect} = require('electron-titlebar-respect') // By SudoVanilla
|
||||
const {TitlebarRespect} = require('electron-titlebar-respect')
|
||||
|
||||
let AppMenu = require('./menu')
|
||||
let Notification = require('./notifications')
|
||||
|
@ -11,18 +10,19 @@ TitlebarRespect({})
|
|||
|
||||
module.exports = {
|
||||
Create: function() {
|
||||
mainWindow = new glasstron.BrowserWindow({
|
||||
title: process.env.Name,
|
||||
mainWindow = new BrowserWindow({
|
||||
title: process.env.Name, // Edit this in .env
|
||||
minWidth: 400,
|
||||
minHeight: 400,
|
||||
width: 1200,
|
||||
height: 800,
|
||||
autoHideMenuBar: true,
|
||||
show: false,
|
||||
blur: true,
|
||||
frame: global.frame,
|
||||
titleBarStyle: global.titleBarStyle,
|
||||
icon: global.AppIcon,
|
||||
frame: global.frame, // Controlled by Electron Titlebar Respect
|
||||
titleBarStyle: global.titleBarStyle, // Controlled by Electron Titlebar Respect
|
||||
icon: global.AppIcon, // Found in ./platform.js
|
||||
vibrancy: 'sidebar',
|
||||
transparent: true,
|
||||
trafficLightPosition: { x: 25, y: 25 }, // Position of Traffic Light buttons on macOS
|
||||
titleBarOverlay: { // Background and Height of Windows titlebar buttons
|
||||
color: '#232323', // Background
|
||||
|
@ -36,7 +36,7 @@ module.exports = {
|
|||
|
||||
// Load Content
|
||||
if (process.env.NODE_ENV === "development") {
|
||||
mainWindow.loadURL('http://localhost:3000') // Use a URL in development mode
|
||||
mainWindow.loadURL('http://localhost:1567') // Use a URL in development mode
|
||||
} else if (process.env.NODE_ENV === 'production') {
|
||||
mainWindow.loadFile('app/index.html') // Do NOT use a URL in production mode, as that can create a security risk for your users who will use this app
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
"description": "",
|
||||
"main": "./electron/index.js",
|
||||
"scripts": {
|
||||
"start": "concurrently \"astro dev\" \"wait-on http://localhost:3000 && NODE_ENV=development electron .\"",
|
||||
"start": "concurrently \"astro dev\" \"wait-on http://localhost:1567 && NODE_ENV=development electron .\"",
|
||||
"build": "astro build && NODE_ENV=production node ./build/prepare-production.js && electron-builder build --config ./build/electron-builder.yml"
|
||||
},
|
||||
"author": "SudoVanilla",
|
||||
|
@ -20,7 +20,6 @@
|
|||
"bugsplat-node": "^3.0.0",
|
||||
"dotenv": "^16.0.3",
|
||||
"electron-titlebar-respect": "^1.1.1",
|
||||
"glasstron-clarity": "^0.1.26",
|
||||
"pushy-electron": "^1.0.11",
|
||||
"replace": "^1.2.2",
|
||||
"sass": "^1.60.0",
|
||||
|
|
Reference in a new issue