illukit
v1.0.2
Published
A Node.js package that helps browsing available illustrations for a given keyword
Downloads
2
Maintainers
Readme
illukit
:gem: A Node.js package that helps browsing available illustrations for a given keyword.
Table of Contents
Installation
Using npm:
$ npm install illukit
Using yarn:
$ yarn add illukit
Methods
lookup(keyword, settings)
keyword
: The keyword that you want to browse some illustrations for.settings
: The object that contains additional settings for the browsing results (Optional).limits
: The maximum number of returned illustrations, defaults to0
.pageName
: The illustrations page to browse (undraw
- default,blush
,drawkit
,ouch
).
Examples
Import the package
NodeJS
const illukit = require('illukit');
ES6/ TypeScript
import illukit from 'illukit';
How to use
(async () => {
try {
const undraw = await illukit.lookup('team', {
limits: 3,
});
const blush = await illukit.lookup('team', {
limits: 0,
pageName: 'blush',
});
console.log(undraw);
/* [
'https://42f2671d685f51e10fc6-b9fcecea3e50b3b59bdc28dead054ebc.ssl.cf5.rackcdn.com/illustrations/team_goals_hrii.svg',
'https://42f2671d685f51e10fc6-b9fcecea3e50b3b59bdc28dead054ebc.ssl.cf5.rackcdn.com/illustrations/team_spirit_hrr4.svg',
'https://42f2671d685f51e10fc6-b9fcecea3e50b3b59bdc28dead054ebc.ssl.cf5.rackcdn.com/illustrations/team_ih79.svg'
] */
console.log(blush);
/* [
'https://cdn.blush.design/collections/big-shoes/v9/Master/Scenes/Team%20Work.png',
'https://cdn.blush.design/collections/family-values/v9/Master/Scenes/Classroom.png'
] */
} catch (error) {
console.log(error);
}
})();