Three additions wire Tailwind v4 into the SPA without disturbing the existing Vuetify pipeline: - apps/app/src/assets/styles/tailwind.css — Tailwind v4 CSS-first entry. Uses @import "tailwindcss"; @plugin "tailwindcss-primeui"; and @source pointing at apps/app/src/ to scan template content. - apps/app/vite.config.ts — adds the @tailwindcss/vite plugin between vue() and vuetify(). After vue() so it sees compiled template content; before vuetify() so Vuetify's SCSS pipeline runs unimpeded. - apps/app/src/main.ts — imports tailwind.css before the Vuetify/Vuexy SCSS so utility classes are available alongside Vuetify's cascade. optimizeDeps.exclude remains ['vuetify'] (no PrimeVue addition) — HMR behaves correctly in dev with the current config; revisit if needed. Verification: - pnpm typecheck — clean. - pnpm build — succeeds in 13.97s; CSS emitted per-route as expected. - pnpm test — 402 tests pass unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
40 lines
1.2 KiB
TypeScript
40 lines
1.2 KiB
TypeScript
import { createApp } from 'vue'
|
|
import { VueQueryPlugin } from '@tanstack/vue-query'
|
|
import { queryClientConfig } from '@/lib/query-client'
|
|
import { initSentry, installContextBinding } from '@/observability'
|
|
import { router } from '@/plugins/1.router'
|
|
|
|
import App from '@/App.vue'
|
|
import { registerPlugins } from '@core/utils/plugins'
|
|
|
|
// Styles
|
|
import '@styles/tailwind.css'
|
|
import '@core/scss/template/index.scss'
|
|
import '@styles/styles.scss'
|
|
|
|
// Create vue app
|
|
const app = createApp(App)
|
|
|
|
// RFC-WS-7 — Sentry init runs before plugin registration so the SDK can
|
|
// hook Vue's errorHandler before any plugin or component initialises.
|
|
// Empty DSN = SDK no-op (mirrors backend behaviour, RFC §3.3).
|
|
initSentry({
|
|
app,
|
|
router,
|
|
dsn: import.meta.env.VITE_SENTRY_DSN_FRONTEND ?? '',
|
|
release: import.meta.env.VITE_SENTRY_RELEASE ?? '',
|
|
environment: import.meta.env.MODE,
|
|
})
|
|
|
|
// Register plugins (router, pinia, vuetify, …).
|
|
registerPlugins(app)
|
|
|
|
// Bind auth-scope tags per route navigation. Must run after pinia is set
|
|
// up by registerPlugins (the guard reads useAuthStore / useOrganisationStore).
|
|
installContextBinding(router)
|
|
|
|
app.use(VueQueryPlugin, queryClientConfig)
|
|
|
|
// Mount vue app
|
|
app.mount('#app')
|