Socket
Book a DemoInstallSign in
Socket

@fkui/i18next-translate

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fkui/i18next-translate

i18next translation provider for FKUI TranslationService

6.16.0
latest
Source
npmnpm
Version published
Maintainers
1
Created
Source

@fkui/i18next-translate

i18next translation provider for FKUI TranslationService.

Usage

import { TranslationService } from "@fkui/logic";
import { i18nextProvider } from "@fkui/i18next-translate";

/* create a new 18next translation provider */
const provider = i18nextProvider({
    defaultLanguage: "sv",
    async loadLanguage(lang) {
        const response = await fetch(`/texts/${lang}.json`);
        return await response.json();
    },
});

/* use provider for TranslationService translations */
TranslationService.changeProvider(provider);

When using Vue and @fkui/vue remenber to enable TranslationPlugin:

import { createApp } from "vue";
import { TranslationPlugin } from "@fkui/vue";
import App from "./App.vue";

const app = createApp(App);

/* enable translation plugin */
app.use(TranslationPlugin);

Keywords

fkui

FAQs

Package last updated on 22 Aug 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.