Forms features
Nuxt Ignis contains following customizable features related to content generation and displaying:
Nuxt Content
Nuxt Content is a powerful content management system for Nuxt applications that allows you to write content in Markdown, JSON, YAML, or CSV formats. It provides a flexible way to manage and display content in your application.
Nuxt Content
integration is disabled by default. To enable it, you can use following environment variable:
NUXT_PUBLIC_IGNIS_CONTENT=true
Usage notice
In order to use @nuxt-content
via Nuxt Ignis, it is currently required to create a custom config file in the root of your project named content.config.ts
with following contents:
// NOTE: explicit import seems to be required
import { loadContentConfig } from './utils/content'
export default loadContentConfig({
// custom config here
//
// custom collections (different than the default "content")
// can be defined here via special `defineContentCollection`, e.g.:
//
// collections: {
// demo: defineContentCollection({
// source: '**',
// type: 'page',
// }),
// },
})
This will reference default config file to enable default @nuxt-content
collection in your project. The extra step is required as it seems not possible to transfer the config file from the layer.
Referencing config like this allows to pass in a custom config that will be defu-merged with the defaults provided by Nuxt Ignis. Alternatively, you can completely ignore Nuxt Ignis' default config and create your own file based on Nuxt Content docs.
I18N
Nuxt I18N is a module that provides internationalization support for your application. It allows you to easily manage translations and switch between different languages.
Nuxt I18N
integration is disabled by default. To enable it, you can use following environment variable:
NUXT_PUBLIC_IGNIS_I18N_ENABLED=true
Additional options
- All
.json
files with messages in@/i18n/locales
folder will be auto-scanned. - You can select default language locale via
NUXT_PUBLIC_IGNIS_I18N_LOCALE
. - If default config file is not suitable for your project, you may specify path to your own using
NUXT_PUBLIC_IGNIS_I18N_CONFIG
.
pslo
This feature exists mainly because Nuxt Ignis origins in Czechia. In Czech language it is considered a typography error to have a single-letter word at the end of a line. To avoid this elrh-pslo
package was created to provide a function to "Prevent Single Letter Orphans. The effect is achieved by replacing ordinary spaces with \xa0
Unicode character using regular expressions.
Nuxt Ignis allows simple integration of this function for more convenience.
elrh-pslo
integration is disabled by default. To enable it, you can use following environment variable:
NUXT_PUBLIC_IGNIS_PSLO_ENABLED=true
Additional options
NUXT_PUBLIC_IGNIS_PSLO_CONTENT
- if bothelrh-pslo
and@nuxt/content
are enabled, this allows or disallows Markdown content pre-processing withpslo
function