cd-core
Common utility and resources (assets)
API
const core = require('cd-core');
core.name (type: string property)
Param | Description |
---|
ret ==> | Module Name |
const name = core.name;
core.version (type: string property)
Param | Description |
---|
ret ==> | Version Number |
const vers = core.version;
core.isWindows (type: function)
Param | Description |
---|
ret ==> | true or false |
const isWindows = core.isWindows();
core.isOSX (type: function)
Param | Description |
---|
ret ==> | true or false |
const isOSX = core.isOSX();
core.isLinux (type: function)
Param | Description |
---|
ret ==> | true or false |
const isLinux = core.isLinux();
core.getAssetPath (type: function)
Param | Description |
---|
ret ==> | Returns full path to asset path (icons, etc.) |
const assetPath = core.getAssetPath();
core.getModuleIcon (type: function)
Param | Description |
---|
ret ==> | Returns path to module icon |
const moduleIconPath = core.getModuleIcon();
core.getFailIcon (type: function)
Param | Description |
---|
ret ==> | Returns path to fail icon |
const failIconPath = core.getFailIcon();
core.getPassIcon (type: function)
Param | Description |
---|
ret ==> | Returns path to pass icon |
const passIconPath = core.getPassIcon();
core.notify (type: function)
Param | Description |
---|
message | Notification Messasge |
options | Notification Options |
showConsole: true or false | |
icon: path to override icon | |
title: title override | |
core.notify('Hello', {showConsole: false});
core.notifyPass (type: function)
Param | Description |
---|
message | Notification Message |
options | Notification Options |
showConsole: true or false | |
icon: path to override icon | |
title: title override | |
core.notifyPass('Process Completed Successfully');
core.notifyFail (type: function)
Param | Description |
---|
message | Notification Message |
options | Notification Options |
showConsole: true or false | |
icon: path to override icon | |
title: title override | |
core.notifyFail('Process Failed To Complete');
License
Copyright © 2017 Mike Erickson
Released under the MIT license
Credits
cd-core written by Mike Erickson
E-Mail: codedungeon@gmail.com
Twitter: @codedungeon
Webiste: codedungeon.org