Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including @lingui/babel-plugin-extract-messages with all npm packages installed. Try it out:

var babelPluginExtractMessages = require("@lingui/babel-plugin-extract-messages")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

@lingui/babel-plugin-extract-messages v2.9.1

Extract messages for translation

License Version Downloads

@lingui/babel-plugin-extract-messages

Babel plugin which extracts messages for translation from source files

@lingui/babel-plugin-extract-messages is part of LinguiJS. See the documentation for all information, tutorials and examples.

Installation

npm install --save-dev @lingui/babel-plugin-extract-messages
# yarn add --dev @lingui/babel-plugin-extract-messages

Usage

Via .babelrc (Recommended)

.babelrc

{
  "plugins": ["@lingui/babel-plugin-extract-messages"]
}

Via CLI

babel --plugins @lingui/babel-plugin-extract-messages script.js

Via Node API

require("@babel/core").transform("code", {
  plugins: ["@lingui/babel-plugin-extract-messages"]
})

License

MIT

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free