
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Queries google's suggestions API
This module is installed via npm:
$ npm install suggestion
var suggest = require('suggestion');
suggest('dog training', function (err, suggestions) {
if (err) throw err;
console.log(suggestions);
/*
[ 'dog training',
'dog training tips',
'dog training collars',
'dog training classes',
'dog training videos',
'dog training houston',
'dog training certification',
'dog training books',
'dog training chicago',
'dog training clicker' ]
*/
})
You can get even more suggestions by appending ' a', ' b', ' c' to your
google suggest query. This does it down to one level from a
to z
.
NB: currently only one level of traversal is supported. Pull requests welcome.
var suggest = require('suggestion');
suggest('dog training', { levels: 1 }, function (err, suggestions) {
if (err) throw err;
console.log(suggestions);
/*
[ 'dog training atlanta',
'dog training austin',
'dog training app',
'dog training albuquerque',
'dog training at home',
'dog training albany ny',
'dog training aids',
'dog training and boarding',
'dog training ann arbor',
'dog training academy',
'dog training books',
.... (260 total results) ...
'dog training zapper',
'dog training zone',
'dog training zoom room',
'dog training zimmerman mn',
'dog training zachary la',
'dog training zak',
'dog training zionsville',
'dog training zebulon nc',
'dog training zionsville indiana' ]
*/
});
Pass in "youtube" as the client
option:
var suggest = require('suggestion');
suggest('dog training', { client: 'youtube' }, function (err, suggestions) {
if (err) throw err;
console.log(suggestions);
/*
[ 'dog training',
'dog training collars',
'dog training tips',
'dog training near me',
'dog training classes',
'dog training videos',
'dog training books',
'dog training schools',
'dog training clicker',
'dog training houston' ]*/
});
Pass in the language code as the hl
option:
var suggest = require('suggestion');
suggest('包', { hl: 'zh-CN' }, function (err, suggestions) {
if (err) throw err;
console.log(suggestions);
/*
[ '包贝尔', '包子', '包子馅',
'包青天', '包菜', '包包', '包', '包容',
'包法利夫人', '包租婆' ]
*/
});
FAQs
Google suggest API
The npm package suggestion receives a total of 156 weekly downloads. As such, suggestion popularity was classified as not popular.
We found that suggestion demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
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.
Security News
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.