3
0

quasar.conf.js 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. // Configuration for your app
  2. const path = require('path')
  3. function resolve (dir) {
  4. return path.join(__dirname, '.', dir)
  5. }
  6. module.exports = function (ctx) {
  7. return {
  8. // app boot file (/src/boot)
  9. // --> boot files are part of "main.js"
  10. boot: [
  11. 'axios',
  12. 'v-charts'
  13. ],
  14. css: [
  15. 'app.styl'
  16. ],
  17. extras: [
  18. 'roboto-font',
  19. 'material-icons' // optional, you are not bound to it
  20. // 'ionicons-v4',
  21. // 'mdi-v3',
  22. // 'fontawesome-v5',
  23. // 'eva-icons'
  24. ],
  25. framework: {
  26. // all: true, // --- includes everything; for dev only!
  27. components: [
  28. 'QPagination',
  29. 'QLayout',
  30. 'QHeader',
  31. 'QDrawer',
  32. 'QPageContainer',
  33. 'QPage',
  34. 'QToolbar',
  35. 'QTabs',
  36. 'QTab',
  37. 'QRouteTab',
  38. 'QToolbarTitle',
  39. 'QBtn',
  40. 'QInput',
  41. 'QTable',
  42. 'QTh',
  43. 'QTr',
  44. 'QTd',
  45. 'QIcon',
  46. 'QList',
  47. 'QItem',
  48. 'QItemSection',
  49. 'QBtnDropdown',
  50. 'QItemLabel',
  51. 'QCard',
  52. 'QCardSection',
  53. 'QCardActions',
  54. 'QCarousel',
  55. 'QCarouselControl',
  56. 'QCarouselSlide',
  57. 'QSeparator',
  58. 'QAvatar'
  59. ],
  60. directives: [
  61. 'TouchSwipe',
  62. 'Ripple'
  63. ],
  64. // Quasar plugins
  65. plugins: [
  66. 'Notify'
  67. ]
  68. // iconSet: 'ionicons-v4'
  69. // lang: 'de' // Quasar language
  70. },
  71. supportIE: false,
  72. build: {
  73. env: ctx.dev
  74. ? { // so on dev we'll have
  75. // API: JSON.stringify('http://39.98.34.197:20006/api')
  76. API: JSON.stringify('http://192.168.0.182:9635/api')
  77. }
  78. : { // and on build (production):
  79. API: JSON.stringify('http://192.168.0.182:9635/api')
  80. },
  81. scopeHoisting: true,
  82. // vueRouterMode: 'history',
  83. // vueCompiler: true,
  84. // gzip: true,
  85. // analyze: true,
  86. // extractCSS: false,
  87. extendWebpack (cfg) {
  88. cfg.module.rules.push({
  89. enforce: 'pre',
  90. test: /\.(js|vue)$/,
  91. loader: 'eslint-loader',
  92. exclude: /node_modules/
  93. }),
  94. cfg.resolve.alias = {
  95. ...cfg.resolve.alias, // This adds the existing alias
  96. // Add you own alias like this
  97. '@': resolve('src')
  98. }
  99. }
  100. },
  101. devServer: {
  102. // https: true,
  103. // port: 8080,
  104. open: true // opens browser window automatically
  105. },
  106. // animations: 'all', // --- includes all animations
  107. animations: [],
  108. ssr: {
  109. pwa: false
  110. },
  111. pwa: {
  112. // workboxPluginMode: 'InjectManifest',
  113. // workboxOptions: {}, // only for NON InjectManifest
  114. manifest: {
  115. // name: 'Quasar App',
  116. // short_name: 'Quasar-PWA',
  117. // description: 'Best PWA App in town!',
  118. display: 'standalone',
  119. orientation: 'portrait',
  120. background_color: '#ffffff',
  121. theme_color: '#027be3',
  122. icons: [
  123. {
  124. 'src': 'statics/icons/icon-128x128.png',
  125. 'sizes': '128x128',
  126. 'type': 'image/png'
  127. },
  128. {
  129. 'src': 'statics/icons/icon-192x192.png',
  130. 'sizes': '192x192',
  131. 'type': 'image/png'
  132. },
  133. {
  134. 'src': 'statics/icons/icon-256x256.png',
  135. 'sizes': '256x256',
  136. 'type': 'image/png'
  137. },
  138. {
  139. 'src': 'statics/icons/icon-384x384.png',
  140. 'sizes': '384x384',
  141. 'type': 'image/png'
  142. },
  143. {
  144. 'src': 'statics/icons/icon-512x512.png',
  145. 'sizes': '512x512',
  146. 'type': 'image/png'
  147. }
  148. ]
  149. }
  150. },
  151. cordova: {
  152. // id: 'org.cordova.quasar.app'
  153. // noIosLegacyBuildFlag: true // uncomment only if you know what you are doing
  154. },
  155. electron: {
  156. // bundler: 'builder', // or 'packager'
  157. extendWebpack (cfg) {
  158. // do something with Electron main process Webpack cfg
  159. // chainWebpack also available besides this extendWebpack
  160. },
  161. packager: {
  162. // https://github.com/electron-userland/electron-packager/blob/master/docs/api.md#options
  163. // OS X / Mac App Store
  164. // appBundleId: '',
  165. // appCategoryType: '',
  166. // osxSign: '',
  167. // protocol: 'myapp://path',
  168. // Window only
  169. // win32metadata: { ... }
  170. },
  171. builder: {
  172. // https://www.electron.build/configuration/configuration
  173. // appId: 'quasar-app'
  174. }
  175. }
  176. }
  177. }