quasar.config.js 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239
  1. /* eslint-env node */
  2. // Configuration for your app
  3. // https://v2.quasar.dev/quasar-cli-vite/quasar-config-js
  4. import { defineConfig } from "#q-app/wrappers";
  5. import { fileURLToPath } from "node:url";
  6. export default defineConfig((ctx) => {
  7. return {
  8. bin: {
  9. linuxAndroidStudio: "/snap/bin/android-studio",
  10. },
  11. // https://v2.quasar.dev/quasar-cli-vite/prefetch-feature
  12. // preFetch: true,
  13. // app boot file (/src/boot)
  14. // --> boot files are part of "main.js"
  15. // https://v2.quasar.dev/quasar-cli-vite/boot-files
  16. boot: [
  17. "axios",
  18. "i18n",
  19. "defaultPropsComponents",
  20. // "socket.io",
  21. ],
  22. // https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#css
  23. css: ["app.scss"],
  24. // https://github.com/quasarframework/quasar/tree/dev/extras
  25. extras: [
  26. // 'ionicons-v4',
  27. "mdi-v7",
  28. // 'fontawesome-v6',
  29. // 'eva-icons',
  30. // 'themify',
  31. // "line-awesome",
  32. // 'roboto-font-latin-ext', // this or either 'roboto-font', NEVER both!
  33. "roboto-font", // optional, you are not bound to it
  34. "material-icons", // optional, you are not bound to it
  35. ],
  36. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#build
  37. build: {
  38. target: {
  39. browser: ["es2022", "firefox115", "chrome115", "safari14"],
  40. node: "node22",
  41. },
  42. vueRouterMode: "history", // available values: 'hash', 'history'
  43. // vueRouterBase,
  44. // vueDevtools,
  45. // vueOptionsAPI: false,
  46. // rebuildCache: true, // rebuilds Vite/linter/etc cache on startup
  47. // publicPath: '/',
  48. // analyze: true,
  49. env: {
  50. API_URL: ctx.dev ? "http://192.168.23.233:8000" : "http://localhost:8000",
  51. PASSWORD: ctx.dev ? "S@ft2080." : "",
  52. WEBSOCKET_API: ctx.dev
  53. ? "http://localhost:4321/"
  54. : "http://localhost:4321/",
  55. WEBSOCKET_PATH: ctx.dev ? "/socket.io" : "/socket.io",
  56. WEBSOCKET_ROOM: ctx.dev ? "LARAVEL" : "LARAVEL",
  57. WEBSOCKET_API_KEY:
  58. "7wArC/kl0nTbt4zBu0agw.NXLyjA96I6x1XmBcuokwPqfo3/CIxzqYw.PTthh5eqa08Uf4ubFlOqatpShoz1CRRID9pZReEFvBk3il6E9u",
  59. },
  60. // rawDefine: {}
  61. // ignorePublicFolder: true,
  62. // minify: false,
  63. // polyfillModulePreload: true,
  64. // distDir
  65. // extendViteConf (viteConf) {},
  66. // viteVuePluginOptions: {},
  67. vitePlugins: [
  68. [
  69. "@intlify/unplugin-vue-i18n/vite",
  70. {
  71. include: [fileURLToPath(new URL("./src/i18n", import.meta.url))],
  72. ssr: ctx.modeName === "ssr",
  73. },
  74. ],
  75. [
  76. "vite-plugin-checker",
  77. {
  78. eslint: {
  79. lintCommand:
  80. 'eslint -c ./eslint.config.js "./src*/**/*.{js,mjs,cjs,vue}"',
  81. useFlatConfig: true,
  82. },
  83. },
  84. { server: false },
  85. ],
  86. ],
  87. },
  88. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#devServer
  89. devServer: {
  90. // https: true
  91. open: true, // opens browser window automatically
  92. },
  93. // https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#framework
  94. framework: {
  95. lang: "pt-BR",
  96. config: {
  97. dark: "auto",
  98. notify: {
  99. position: "top-right",
  100. },
  101. },
  102. // iconSet: 'material-icons', // Quasar icon set
  103. // lang: 'en-US', // Quasar language pack
  104. // For special cases outside of where the auto-import strategy can have an impact
  105. // (like functional components as one of the examples),
  106. // you can manually specify Quasar components/directives to be available everywhere:
  107. //
  108. // components: [],
  109. // directives: [],
  110. // Quasar plugins
  111. plugins: ["Dialog", "Notify", "Loading", "Cookies", "Dark"],
  112. },
  113. // animations: 'all', // --- includes all animations
  114. // https://v2.quasar.dev/options/animations
  115. animations: [],
  116. // https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#property-sourcefiles
  117. // sourceFiles: {
  118. // rootComponent: 'src/App.vue',
  119. // router: 'src/router/index',
  120. // store: 'src/store/index',
  121. // pwaRegisterServiceWorker: 'src-pwa/register-service-worker',
  122. // pwaServiceWorker: 'src-pwa/custom-service-worker',
  123. // pwaManifestFile: 'src-pwa/manifest.json',
  124. // electronMain: 'src-electron/electron-main',
  125. // electronPreload: 'src-electron/electron-preload'
  126. // bexManifestFile: 'src-bex/manifest.json
  127. // },
  128. // https://v2.quasar.dev/quasar-cli-vite/developing-ssr/configuring-ssr
  129. ssr: {
  130. prodPort: 3000, // The default port that the production server should use
  131. // (gets superseded if process.env.PORT is specified at runtime)
  132. middlewares: [
  133. "render", // keep this as last one
  134. ],
  135. // extendPackageJson (json) {},
  136. // extendSSRWebserverConf (esbuildConf) {},
  137. // manualStoreSerialization: true,
  138. // manualStoreSsrContextInjection: true,
  139. // manualStoreHydration: true,
  140. // manualPostHydrationTrigger: true,
  141. pwa: false,
  142. // pwaOfflineHtmlFilename: 'offline.html', // do NOT use index.html as name!
  143. // will mess up SSR
  144. // pwaExtendGenerateSWOptions (cfg) {},
  145. // pwaExtendInjectManifestOptions (cfg) {}
  146. },
  147. // https://v2.quasar.dev/quasar-cli-vite/developing-pwa/configuring-pwa
  148. pwa: {
  149. workboxMode: "GenerateSW", // 'GenerateSW' or 'InjectManifest'
  150. // swFilename: 'sw.js',
  151. // manifestFilename: 'manifest.json'
  152. // extendManifestJson (json) {},
  153. // useCredentialsForManifestTag: true,
  154. // injectPwaMetaTags: false,
  155. // extendPWACustomSWConf (esbuildConf) {},
  156. // extendGenerateSWOptions (cfg) {},
  157. // extendInjectManifestOptions (cfg) {}
  158. },
  159. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/developing-cordova-apps/configuring-cordova
  160. cordova: {
  161. // noIosLegacyBuildFlag: true, // uncomment only if you know what you are doing
  162. },
  163. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/developing-capacitor-apps/configuring-capacitor
  164. capacitor: {
  165. hideSplashscreen: true,
  166. },
  167. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/developing-electron-apps/configuring-electron
  168. electron: {
  169. // extendElectronMainConf (esbuildConf) {},
  170. // extendElectronPreloadConf (esbuildConf) {},
  171. // extendPackageJson (json) {},
  172. // Electron preload scripts (if any) from /src-electron, WITHOUT file extension
  173. preloadScripts: ["electron-preload"],
  174. // specify the debugging port to use for the Electron app when running in development mode
  175. inspectPort: 5858,
  176. bundler: "packager", // 'packager' or 'builder'
  177. packager: {
  178. // https://github.com/electron-userland/electron-packager/blob/master/docs/api.md#options
  179. // OS X / Mac App Store
  180. // appBundleId: '',
  181. // appCategoryType: '',
  182. // osxSign: '',
  183. // protocol: 'myapp://path',
  184. // Windows only
  185. // win32metadata: { ... }
  186. },
  187. builder: {
  188. // https://www.electron.build/configuration/configuration
  189. appId: "quasar-skeleton",
  190. },
  191. },
  192. // Full list of options: https://v2.quasar.dev/quasar-cli-vite/developing-browser-extensions/configuring-bex
  193. bex: {
  194. // extendBexScriptsConf (esbuildConf) {},
  195. // extendBexManifestJson (json) {},
  196. contentScripts: ["my-content-script"],
  197. },
  198. };
  199. });