refactor: move frontend code into view
This commit is contained in:
2
build.ts
2
build.ts
@@ -5,7 +5,7 @@ import path from "node:path";
|
||||
const outdir = path.join(process.cwd(), "dist");
|
||||
await rm(outdir, { recursive: true, force: true });
|
||||
|
||||
const entrypoints = [...new Bun.Glob("src/**/*.html").scanSync()];
|
||||
const entrypoints = [...new Bun.Glob("view/**/*.html").scanSync()];
|
||||
|
||||
const result = await Bun.build({
|
||||
entrypoints,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"tsx": true,
|
||||
"tailwind": {
|
||||
"config": "",
|
||||
"css": "styles/globals.css",
|
||||
"css": "view/styles/globals.css",
|
||||
"baseColor": "neutral",
|
||||
"cssVariables": true,
|
||||
"prefix": ""
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { serve } from "bun";
|
||||
import index from "./index.html";
|
||||
import index from "../view/index.html";
|
||||
|
||||
const server = serve({
|
||||
routes: {
|
||||
|
||||
@@ -23,7 +23,9 @@
|
||||
"noImplicitOverride": true,
|
||||
|
||||
"paths": {
|
||||
"@/*": ["./src/*"]
|
||||
"@/*": ["./view/*"],
|
||||
"@view/*": ["./view/*"],
|
||||
"@core/*": ["./core/*"]
|
||||
},
|
||||
|
||||
// Some stricter flags (disabled by default)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* This file is the entry point for the React app, it sets up the root
|
||||
* element and renders the App component to the DOM.
|
||||
*
|
||||
* It is included in `src/index.html`.
|
||||
* It is included in `view/index.html`.
|
||||
*/
|
||||
|
||||
import { StrictMode } from "react";
|
||||
@@ -1,4 +1,4 @@
|
||||
@import "../styles/globals.css";
|
||||
@import "./styles/globals.css";
|
||||
|
||||
@layer base {
|
||||
:root {
|
||||
Reference in New Issue
Block a user