mirror of
https://github.com/ZSeven-W/openpencil.git
synced 2026-06-01 03:14:29 +07:00
Set up the Fabric.js v7 canvas integration with bidirectional sync to a Zustand document store. Includes drawing tools (select, rectangle, ellipse, line, text, frame, hand), viewport pan/zoom, smart guides, dimension labels, and the main editor layout with toolbar and status bar. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
32 lines
842 B
TypeScript
32 lines
842 B
TypeScript
import { defineConfig } from 'vite'
|
|
import { devtools } from '@tanstack/devtools-vite'
|
|
import { tanstackStart } from '@tanstack/react-start/plugin/vite'
|
|
import viteReact from '@vitejs/plugin-react'
|
|
import viteTsConfigPaths from 'vite-tsconfig-paths'
|
|
import { fileURLToPath, URL } from 'node:url'
|
|
import tailwindcss from '@tailwindcss/vite'
|
|
import { nitro } from 'nitro/vite'
|
|
|
|
const config = defineConfig({
|
|
resolve: {
|
|
alias: {
|
|
'@': fileURLToPath(new URL('./src', import.meta.url)),
|
|
},
|
|
},
|
|
plugins: [
|
|
devtools(),
|
|
nitro({
|
|
rollupConfig: { external: [/^@sentry\//] },
|
|
serverDir: './server',
|
|
}),
|
|
// this is the plugin that enables path aliases
|
|
viteTsConfigPaths({
|
|
projects: ['./tsconfig.json'],
|
|
}),
|
|
tailwindcss(),
|
|
tanstackStart(),
|
|
viteReact(),
|
|
],
|
|
})
|
|
|
|
export default config
|