Skip to content

Support more languages #389

@v1r0x

Description

@v1r0x

Currently Spacialist only supports english and german language. Any other language is very welcome! No matter if they are widespread (as e.g. french, italian, arabic) or endangered (e.g. hawaiian).

To add translations for another language simply

  1. duplicate resources/js/i18n/en.js and rename it to match your country code and, if required, your region (e.g. fr for french or en-gb for british english or simply en for non-regional english vocabulary).
  2. Rename in the first line of your duplicated file const en to const CODE and at the end of your file export default en to export default CODE
  3. Edit resources/js/bootstrap/i18n.js and import your new added language (import CODE from ../i18n/CODE) and add it to the messages object

Example (adding french)

Before

// Some imports ...
import en from '../i18n/en';
import de from '../i18n/de';

const messages = {
    en: en,
    de: de
}

// More code

After

// Some imports ...
import en from '../i18n/en';
import de from '../i18n/de';
import fr from '../i18n/fr';

const messages = {
    en: en,
    de: de,
    fr: fr,
}

// More code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions