mirror of
https://github.com/open-webui/desktop
synced 2025-06-26 18:15:59 +00:00
feat: vite+svelte+tailwind setup
This commit is contained in:
@@ -1,7 +0,0 @@
|
||||
body {
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica,
|
||||
Arial, sans-serif;
|
||||
margin: auto;
|
||||
max-width: 38rem;
|
||||
padding: 2rem;
|
||||
}
|
||||
11
src/render/App.svelte
Normal file
11
src/render/App.svelte
Normal file
@@ -0,0 +1,11 @@
|
||||
<script lang="ts">
|
||||
import { onMount } from "svelte";
|
||||
|
||||
onMount(() => {
|
||||
console.log("Mounted");
|
||||
});
|
||||
</script>
|
||||
|
||||
<main>
|
||||
<div class=" text-xl font-bold">Open WebUI App</div>
|
||||
</main>
|
||||
1
src/render/app.css
Normal file
1
src/render/app.css
Normal file
@@ -0,0 +1 @@
|
||||
@import "tailwindcss";
|
||||
@@ -1,31 +1,9 @@
|
||||
/**
|
||||
* This file will automatically be loaded by vite and run in the "renderer" context.
|
||||
* To learn more about the differences between the "main" and the "renderer" context in
|
||||
* Electron, visit:
|
||||
*
|
||||
* https://electronjs.org/docs/tutorial/application-architecture#main-and-renderer-processes
|
||||
*
|
||||
* By default, Node.js integration in this file is disabled. When enabling Node.js integration
|
||||
* in a renderer process, please be aware of potential security implications. You can read
|
||||
* more about security risks here:
|
||||
*
|
||||
* https://electronjs.org/docs/tutorial/security
|
||||
*
|
||||
* To enable Node.js integration in this file, open up `main.ts` and enable the `nodeIntegration`
|
||||
* flag:
|
||||
*
|
||||
* ```
|
||||
* // Create the browser window.
|
||||
* mainWindow = new BrowserWindow({
|
||||
* width: 800,
|
||||
* height: 600,
|
||||
* webPreferences: {
|
||||
* nodeIntegration: true
|
||||
* }
|
||||
* });
|
||||
* ```
|
||||
*/
|
||||
import { mount } from 'svelte'
|
||||
import './render/app.css'
|
||||
import App from './render/App.svelte'
|
||||
|
||||
import './index.css';
|
||||
const app = mount(App, {
|
||||
target: document.getElementById('app'),
|
||||
})
|
||||
|
||||
console.log('👋 This message is being logged by "renderer.ts", included via Vite');
|
||||
export default app
|
||||
|
||||
Reference in New Issue
Block a user