Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

translation-gen

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

translation-gen

Generate translate json by google sheet automatically

  • 0.1.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
42
decreased by-6.67%
Maintainers
1
Weekly downloads
 
Created
Source

translation-gen NPM MIT

Generate translation json file by Google Sheets


Installation

yarn add translation-gen -D

// or pnpm i translation-gen -D

Usage

  1. Create Service Account and key Link
  2. Add translationgen.yaml on root of your project
  3. Set up translationgen.yaml
  4. Add ENV variable TRANSLATIONGEN_PRIVATE_KEY_PATH into .env file
TRANSLATIONGEN_PRIVATE_KEY_PATH="/path/to/key.json"
  1. Add script in package.json
{
    ...
    "scripts": {
        "transgen": translationgen
    }
}
  1. Run script
$ yarn transgen
  1. Take a look at the output directory in your project. (default: /translation)

translationgen.yaml

KEYDescriptiondefault
targetGoogle sheet file URL-
serviceAccountGoogle Service Account email Link-
sheetTitle of sheet-
sheetIdID of sheet-
outputoutput directory path-
localesArray<locale>, example: ['ko', 'en']-
localesseparator of key to represent depth"."

Example

target: https://docs.google.com/spreadsheets/d/adfkljjdfslkjlk/edit#gid=0
serviceAccount: google-workspace-manager@your_project.iam.gserviceaccount.com
output: "./translation"
locales: ["ko", "en", "jp"]
sheet: "translation"
sheetId: your_sheet_id
depthSeparator: $

Keywords

FAQs

Package last updated on 04 Jan 2024

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc