Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pfzhengd/vue-i18n-aux
About the Vue i18n auxiliary tool with VSCode.
https://github.com/pfzhengd/vue-i18n-aux
i18n i18n-helper i18n-manage i18n-tool vue vue-i18n
Last synced: about 1 month ago
JSON representation
About the Vue i18n auxiliary tool with VSCode.
- Host: GitHub
- URL: https://github.com/pfzhengd/vue-i18n-aux
- Owner: pfzhengd
- License: mit
- Created: 2019-05-16T14:05:10.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-05-01T05:14:05.000Z (over 4 years ago)
- Last Synced: 2024-08-03T09:13:12.710Z (4 months ago)
- Topics: i18n, i18n-helper, i18n-manage, i18n-tool, vue, vue-i18n
- Language: TypeScript
- Homepage: https://marketplace.visualstudio.com/items?itemName=vue-i18n-manage.vue-i18n-manage
- Size: 26.6 MB
- Stars: 10
- Watchers: 1
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.en-US.md
- License: LICENSE
Awesome Lists containing this project
- awesome-github-star - vue-i18n-aux
README
## Vue i18n aux
项目中开发使用到Vue-i18n的辅助工具。![Visual Studio Marketplace Version](https://img.shields.io/visual-studio-marketplace/v/vue-i18n-manage.vue-i18n-manage.svg?style=flat-square)
![Visual Studio Marketplace Installs](https://img.shields.io/visual-studio-marketplace/i/vue-i18n-manage.vue-i18n-manage.svg?style=flat-square)
![Visual Studio Marketplace Downloads](https://img.shields.io/visual-studio-marketplace/d/vue-i18n-manage.vue-i18n-manage.svg?style=flat-square)## Installation
1. 安装Vue-i18n依赖
2. 在VS Code中搜索安装vue-i18n-aux
3. 文件-首选项-设置-配置Primary Language## Features
1. 开发文件中预览i18n
2. 选中提取自动生成Key## Preview
![src/static/vue-i18n-manage.gif](src/static/vue-i18n-manage.gif)## Directory structure
```
locale
├── en-US
| ├── demo.json
| ├── ...
├── zh-CN
| ├── demo.json
| ├── ...
└── index.js
```
## Example
```JS// index.js
const enDemo = require('./en-US/demo.json')
const cnDemo = require('./zh-CN/demo.json')export default {
en: enDemo,
cn: cnDemo
}// main.js
import Vue from 'vue'
import App from './App'
import messages from './locale'
import VueI18n from 'vue-i18n'const i18n = new VueI18n({
locale: 'cn',
messages: messages
})window.instance = new Vue({
el: '#app',
i18n,
render: h => h(App)
})```
## configuration
```
//配置当前开发的主要语言目录名
"vue-i18n-manage.primaryLanguage": "zh-CN"
```## License
[MIT](https://github.com/flyer-ui/vue-i18n-manage/blob/master/LICENSE) © 2019 [Zheng peng fei](https://github.com/pfzhengd)