Skip to content

Commit ec90828

Browse files
authored
WordPress i18n package: Initial commit (#96)
1 parent 0004c6a commit ec90828

11 files changed

Lines changed: 1004 additions & 0 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
package-lock=false
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Babel Plugin Makepot
2+
======
3+
4+
Babel plugin used to scan JavaScript files for use of localization functions. It then compiles these into a [gettext POT formatted](https://en.wikipedia.org/wiki/Gettext) file as a template for translation. By default the output file will be written to `gettext.pot` of the root project directory. This can be overridden using the `"output"` option of the plugin.
5+
6+
```json
7+
[ "@wordpress/babel-plugin-makepot", {
8+
"output": "languages/myplugin.pot"
9+
} ]
10+
```
11+
12+
## Installation
13+
14+
Install the module:
15+
16+
```bash
17+
npm install @wordpress/babel-plugin-makepot --save-dev
18+
```
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{
2+
"name": "@wordpress/babel-plugin-makepot",
3+
"version": "1.0.0-beta.0",
4+
"description": "WordPress Babel i18n Plugin",
5+
"author": "WordPress",
6+
"license": "GPL-2.0-or-later",
7+
"keywords": [
8+
"i18n",
9+
"babel",
10+
"plugin"
11+
],
12+
"homepage": "https://github.com/WordPress/packages/tree/master/packages/babel-plugin-makepot/README.md",
13+
"repository": {
14+
"type": "git",
15+
"url": "https://github.com/WordPress/packages.git"
16+
},
17+
"bugs": {
18+
"url": "https://github.com/WordPress/packages/issues"
19+
},
20+
"main": "build/index.js",
21+
"module": "build-module/index.js",
22+
"publishConfig": {
23+
"access": "public"
24+
},
25+
"dependencies": {
26+
"gettext-parser": "^1.3.1",
27+
"lodash": "^4.17.5"
28+
},
29+
"devDependencies": {
30+
"babel-core": "^6.26.0",
31+
"babel-traverse": "^6.26.0"
32+
}
33+
}

0 commit comments

Comments
 (0)