Fix frontend paths

This commit is contained in:
Laura Hausmann 2024-01-08 17:59:18 +01:00
parent 18dcdfb211
commit 737e00bffc
No known key found for this signature in database
GPG key ID: D044E84C5BE01605
5 changed files with 4 additions and 5 deletions

2
.gitignore vendored
View file

@ -92,7 +92,7 @@ fabric.properties
# End of https://www.toptal.com/developers/gitignore/api/dotnetcore,rider # End of https://www.toptal.com/developers/gitignore/api/dotnetcore,rider
Iceshrimp.Backend/configuration.overrides.ini Iceshrimp.Backend/configuration.overrides.ini
Iceshrimp.Backend/wwwroot/frontend Iceshrimp.Backend/wwwroot/assets
Iceshrimp.Backend/wwwroot/.vite Iceshrimp.Backend/wwwroot/.vite
Iceshrimp.Frontend/.yarn Iceshrimp.Frontend/.yarn

View file

@ -7,8 +7,8 @@
<head> <head>
<meta charset="utf-8"/> <meta charset="utf-8"/>
<title>Iceshrimp</title> <title>Iceshrimp</title>
<link rel="stylesheet" vite-href="/frontend/src/main.ts" asp-append-version="true"/> <link rel="stylesheet" vite-href="/src/main.ts" asp-append-version="true"/>
<script type="module" vite-src="/frontend/src/main.ts" asp-append-version="true"></script> <script type="module" vite-src="/src/main.ts" asp-append-version="true"></script>
</head> </head>
<body> <body>
<div id="app"></div> <div id="app"></div>

View file

@ -23,7 +23,6 @@ builder.Services.AddViteServices(options => {
options.PackageManager = "yarn"; options.PackageManager = "yarn";
options.Server.AutoRun = false; //TODO: Fix script generation on macOS options.Server.AutoRun = false; //TODO: Fix script generation on macOS
options.Server.UseFullDevUrl = true; options.Server.UseFullDevUrl = true;
options.Base = "frontend"; // relative to wwwroot
}); });
builder.Services.AddLogging(logging => logging.AddSimpleConsole(options => { builder.Services.AddLogging(logging => logging.AddSimpleConsole(options => {
options.SingleLine = true; options.SingleLine = true;

View file

@ -7,6 +7,7 @@
"scripts": { "scripts": {
"dev": "vite", "dev": "vite",
"build": "vue-tsc && vite build", "build": "vue-tsc && vite build",
"gulp": "rm -rf ../Iceshrimp.Backend/wwwroot/assets ../Iceshrimp.Backend/wwwroot/.vite && cp -R ./dist/ ../Iceshrimp.Backend/wwwroot",
"preview": "vite preview" "preview": "vite preview"
}, },
"devDependencies": { "devDependencies": {

View file

@ -12,7 +12,6 @@ export default defineConfig({
}), }),
], ],
build: { build: {
outDir: '../Iceshrimp.Backend/wwwroot/frontend',
emptyOutDir: true, emptyOutDir: true,
manifest: true, manifest: true,
rollupOptions: { rollupOptions: {