3.0.4 • Published 4 years ago

@sparing-software/nuxt-sparing-center v3.0.4

Weekly downloads
17
License
MIT
Repository
github
Last release
4 years ago

Installation

Install package in your project

npm i @sparing-software/nuxt-sparing-center

Configuration

Add module in nuxt.config.js

modules: [
  ['@sparing-software/nuxt-sparing-center', {
    // ... options
  }]
]

Options

OptionDescriptionDefault
pluginsImport nuxt plugins without any installation or configuration. Available plugins: ['vue-on-resize', 'v-clamp', '100vh'],[]
openApiServiceImport sparing-open-api. Available options: true, falsetrue
trailingSlashForcing/force removing trailing slash at the end of the urls. Available options: true, false, null. Caveat: required nuxtjs version is 2.10.1+null
axiosI18nHeaderAdd Accept-Language header with current i18n.locale value to every axios request. Caveat: @sparing-software/nuxt-sparing-center must be set before @nuxtjs/axios module.false
styleResourcesImport @/assets/sass/_vars.scss and @/assets/sass/_mixins.scss to every vue component.true
sassUtilsCollectionImport sass-utils-collection - styleResources must be enabled.true
boxSizingSet global box-sizing: border-boxtrue
fixBrowserStylesOverwrite user agent styles: 'reset', 'normalize', false'reset'
fixFontSmoothingFix default font-smoothing: true, falsetrue

Example

['@sparing-software/nuxt-sparing-center', {
  trailingSlash: true,
  serviceModule: {
    httpClient: 'path/to/httpClient'
  },
  axiosI18nHeader: true,
  plugins: [
    'v-clamp',
    'vue-on-resize'
  ]
}]

Contributing

Want to help improve this plugin? Great!
Project is open-source so fork repo and join us!

License

MIT License © Sparing Interactive