vue.config.js 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. module.exports = {
  2. publicPath: process.env.NODE_ENV === 'production' ? '/mobile/' : '/',
  3. outputDir: 'dist',
  4. devServer: {
  5. proxy: {
  6. '/mobile/api': {
  7. target: 'http://localhost:9099/',
  8. changeOrigin: true,
  9. logLevel: 'info',
  10. },
  11. },
  12. },
  13. pwa: {
  14. manifestOptions: {
  15. name: 'SGC Mobile',
  16. short_name: 'SGC Mobile',
  17. start_url: './',
  18. display: 'standalone',
  19. background_color: '#ed1c24',
  20. theme_color : '#ed1c24',
  21. version : (new Date()).toLocaleDateString('ko-KR').replace(/ /gi,'').replace(/\.$/gi,''),
  22. icons: [
  23. {
  24. sizes: '20x20',
  25. src: './img/icons/android-chrome-20x20.png',
  26. type: 'image/png',
  27. purpose: 'any',
  28. },
  29. {
  30. sizes: '29x29',
  31. src: './img/icons/android-chrome-29x29.png',
  32. type: 'image/png',
  33. purpose: 'any',
  34. },
  35. {
  36. sizes: '40x40',
  37. src: './img/icons/android-chrome-40x40.png',
  38. type: 'image/png',
  39. purpose: 'any',
  40. },
  41. {
  42. sizes: '76x76',
  43. src: './img/icons/android-chrome-76x76.png',
  44. type: 'image/png',
  45. purpose: 'any',
  46. },
  47. {
  48. sizes: '144x144',
  49. src: './img/icons/android-chrome-144x144.png',
  50. type: 'image/png',
  51. purpose: 'any',
  52. },
  53. {
  54. sizes: '167x167',
  55. src: './img/icons/android-chrome-167x167.png',
  56. type: 'image/png',
  57. purpose: 'any',
  58. },
  59. {
  60. sizes: '192x192',
  61. src: './img/icons/android-chrome-192x192.png',
  62. type: 'image/png',
  63. purpose: 'any',
  64. },
  65. {
  66. sizes: '512x512',
  67. src: './img/icons/android-chrome-512x512.png',
  68. type: 'image/png',
  69. purpose: 'any',
  70. },
  71. {
  72. sizes: '192x192',
  73. src: './img/icons/android-chrome-maskable-192x192.png',
  74. purpose: 'maskable',
  75. type: 'image/png',
  76. },
  77. {
  78. sizes: '512x512',
  79. src: './img/icons/android-chrome-maskable-512x512.png',
  80. purpose: 'maskable',
  81. type: 'image/png',
  82. },
  83. ],
  84. protocol_handlers : [
  85. {
  86. "protocol": "web+defting",
  87. "url": "/mobile/#/as/defting/%s"
  88. },
  89. {
  90. "protocol": "web+deftdone",
  91. "url": "/mobile/#/as/deftdone/%s"
  92. },
  93. {
  94. "protocol": "web+deftmang",
  95. "url": "/mobile/#/po/deftmang/%s"
  96. },
  97. {
  98. "protocol": "web+deftque",
  99. "url": "/mobile/#/po/deftque/%s"
  100. }
  101. ],
  102. shortcuts: [
  103. {
  104. name: 'Home',
  105. description: 'Home Page',
  106. url: '/#home',
  107. icons: [
  108. {
  109. sizes: '96x96',
  110. src: './img/icons/menu-home-96x96.png',
  111. type: 'image/png',
  112. },
  113. ],
  114. },
  115. {
  116. name: '하자처리',
  117. description: '하자처리',
  118. url: '/#/as/defting',
  119. icons: [
  120. {
  121. sizes: '96x96',
  122. src: './img/icons/menu-defting-96x96.png',
  123. type: 'image/png',
  124. },
  125. ],
  126. },
  127. {
  128. name: '하자완료조회',
  129. description: '하자완료조회',
  130. url: '/#/as/deftdone',
  131. icons: [
  132. {
  133. sizes: '96x96',
  134. src: './img/icons/menu-deftdone-96x96.png',
  135. type: 'image/png',
  136. },
  137. ],
  138. },
  139. {
  140. name: '하자작업지시',
  141. description: '하자작업지시',
  142. url: '/#/po/deftmang',
  143. icons: [
  144. {
  145. sizes: '96x96',
  146. src: './img/icons/menu-deftmang-96x96.png',
  147. type: 'image/png',
  148. },
  149. ],
  150. },
  151. {
  152. name: '하자조회및완료처리',
  153. description: '하자조회및완료처리',
  154. url: '/#/po/deftque',
  155. icons: [
  156. {
  157. sizes: '96x96',
  158. src: './img/icons/menu-deftque-96x96.png',
  159. type: 'image/png',
  160. },
  161. ],
  162. },
  163. {
  164. name: '회의실예약',
  165. description: '회의실예약',
  166. url: '/#/po/roomrev',
  167. icons: [
  168. {
  169. sizes: '96x96',
  170. src: './img/icons/menu-roomrev-96x96.png',
  171. type: 'image/png',
  172. },
  173. ],
  174. },
  175. {
  176. name: '회의실예약승인',
  177. description: '회의실예약승인',
  178. url: '/#/po/roomapp',
  179. icons: [
  180. {
  181. sizes: '96x96',
  182. src: './img/icons/menu-roomapp-96x96.png',
  183. type: 'image/png',
  184. },
  185. ],
  186. },
  187. ],
  188. orientation: 'portrait',
  189. },
  190. themeColor : '#364855',
  191. // msapplicationTileColor: '#000000',
  192. appleMobileWebAppTitle: 'SGC Mobile',
  193. appleMobileWebAppCapable: 'yes',
  194. appleMobileWebAppStatusBarStyle: 'black-translucent',
  195. iconPaths: {
  196. maskicon: null,
  197. favicon32: './img/icons/favicon-32x32.png',
  198. favicon16: './img/icons/favicon-16x16.png',
  199. appleTouchIcon: './img/icons/android-chrome-180x180.png',
  200. msTileImage: null,
  201. },
  202. // configure the workbox plugin
  203. workboxPluginMode: 'GenerateSW',
  204. },
  205. configureWebpack: {
  206. performance: {
  207. hints: false,
  208. },
  209. optimization: {
  210. splitChunks: {
  211. minSize: 10000,
  212. maxSize: 550000,
  213. },
  214. },
  215. },
  216. };