🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

github.com/icrowley/go-yandex-dictionary

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/icrowley/go-yandex-dictionary

v0.0.0-20180809105718-62517a1139fe
Source
Go
Version published
Created
Source

Build Status GoDoc Go Report Card Coverage Status

go-yandex-dictionary

Go Yandex Dictionary API wrapper

Usage:

package main

import (
  "fmt"
  "github.com/dafanasev/go-yandex-dictionary"
)

func main() {
  dict := dictionary.New("YOUR_API_KEY")

  langs, err := dict.GetLangs()

  if err != nil {
    fmt.Println(err)
  } else {
    fmt.Println(langs)
  }

  definition, err := dict.Lookup(&dictionary.Params{Lang: "en-ru", Text: "Dog"})

  if err != nil {
    fmt.Println(err)
  } else {
    fmt.Println(definition.Def[0].Text)
  }
}

FAQs

Package last updated on 09 Aug 2018

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