@lingui/extractor-vue
TypeScript icon, indicating that this package has built-in type declarations

4.14.0 • Public • Published

License Version Downloads

@lingui/vue-extractor

This package contains a custom extractor that handles Vue.js files. It supports extracting messages from script and setup scripts as well as Vue templates.

@lingui/vue-extractor is part of LinguiJS. See the documentation for all information, tutorials and examples.

Installation

npm install --save-dev @lingui/extractor-vue

Usage

This custom extractor requires that you use JavaScript or TypeScript for your Lingui configuration.

import { vueExtractor } from "@lingui/extractor-vue"
import { extractor as defaultExtractor } from "@lingui/cli/api"

/** @type {import('@lingui/conf').LinguiConfig} */
const linguiConfig = {
  locales: ["en", "nb"],
  sourceLocale: "en",
  catalogs: [
    {
      path: "<rootDir>/src/{locale}",
      include: ["<rootDir>/src"],
    },
  ],
  extractors: [defaultExtractor, vueExtractor],
}

export default linguiConfig

License

This package is licensed under MIT license.

Dependents (0)

Package Sidebar

Install

npm i @lingui/extractor-vue

Weekly Downloads

44

Version

4.14.0

License

MIT

Unpacked Size

8.78 kB

Total Files

9

Last publish

Collaborators

  • andrii.bodnar
  • serhiydmytryshyn