nuxt.config.js 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. export default {
  2. // Enable server-side rendering (https://go.nuxtjs.dev/ssr-mode)
  3. ssr: false,
  4. // Auto import components (https://go.nuxtjs.dev/config-components)
  5. components: true,
  6. head: {
  7. titleTemplate: 'Frames, par Opentalent',
  8. title: 'frames',
  9. meta: [
  10. { charset: 'utf-8' },
  11. { name: 'viewport', content: 'width=device-width, initial-scale=1' },
  12. { hid: 'description', name: 'description', content: '' },
  13. ],
  14. link: [
  15. { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
  16. ]
  17. },
  18. // Global CSS: https://go.nuxtjs.dev/config-css
  19. css: [
  20. '~/assets/style/global.scss'
  21. ],
  22. i18n: {
  23. locales: [
  24. {
  25. code: 'fr',
  26. file: 'fr-FR.js'
  27. }
  28. ],
  29. lazy: true,
  30. langDir: 'lang/',
  31. defaultLocale: 'fr',
  32. vueI18n: {
  33. silentTranslationWarn: true,
  34. silentFallbackWarn: true
  35. }
  36. },
  37. // Plugins to run before rendering page: https://go.nuxtjs.dev/config-plugins
  38. plugins: [
  39. { src: '~/plugins/vue2-leaflet-markercluster.js', mode: 'client' },
  40. { src: '~/plugins/theming.js', mode: 'client' },
  41. { src: '~/plugins/iframeResizer.js', mode: 'client' }
  42. ],
  43. // Modules for dev and build (recommended): https://go.nuxtjs.dev/config-modules
  44. buildModules: [
  45. // https://go.nuxtjs.dev/typescript
  46. '@nuxt/typescript-build',
  47. // https://go.nuxtjs.dev/vuetify
  48. '@nuxtjs/vuetify'
  49. ],
  50. // Modules: https://go.nuxtjs.dev/config-modules
  51. modules: [
  52. '@nuxtjs/i18n',
  53. '@nuxtjs/axios',
  54. 'nuxt-leaflet',
  55. [
  56. 'nuxt-fontawesome', {
  57. imports: [
  58. {
  59. set: '@fortawesome/free-solid-svg-icons',
  60. icons: ['fas']
  61. },
  62. {
  63. set: '@fortawesome/free-brands-svg-icons',
  64. icons: ['fab']
  65. }
  66. ]
  67. }
  68. ]
  69. ],
  70. // Vuetify module configuration
  71. // @see https://vuetifyjs.com/en/features/theme/
  72. vuetify: {
  73. customVariables: ['~/assets/style/variables.scss'],
  74. treeShake: true,
  75. theme: {
  76. themes: {
  77. light: {
  78. primary: '#e4611b'
  79. }
  80. },
  81. options: {
  82. customProperties: true
  83. }
  84. }
  85. },
  86. // Build Configuration: https://go.nuxtjs.dev/config-build
  87. build: {
  88. },
  89. // Env
  90. publicRuntimeConfig: {
  91. baseURL: process.env.CLIENT_API_BASE_URL,
  92. axios: {
  93. https: true,
  94. browserBaseURL: process.env.CLIENT_API_BASE_URL
  95. }
  96. },
  97. privateRuntimeConfig: {
  98. baseURL: process.env.SSR_API_BASE_URL,
  99. axios: { baseURL: process.env.SSR_API_BASE_URL }
  100. }
  101. }