Research
Security News
Threat Actor Exposes Playbook for Exploiting npm to Build Blockchain-Powered Botnets
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
loops-tools
Advanced tools
Includes every thing the need to be included while developing loops web pages (web apps) author lishuo@mozat.com
in your VUE app:
...
import LoopsTools from 'loops-tools';
...
Vue.use(LoopsTools);
// or
Vue.use(LoopsTools, { env: 'production' }); // for production env
// production env will use production API URL and all production settings.
install params:
wanna call an API?
import { api, request } from 'loops-tools';
// no uid & token param needed. will auto get params from **url param**
// **UNLESS** you manually pass it into the **params**. that will override the url params.
request(api.topupReward, ${params})
.then(res => {
...
// do every thing with your result.
})
// or
api.topupReward.request(${params})
.then(res =>{
...
// same here or different code styles.
})
other tools:
import { inapp, points } from 'loops-tools';
// wanna inject a DI point?
inapp.di(points(${pointid}));
// wanna open a app page?
inapp.openAppPage(${pageName}});
// wanna get other url params?
import { utils } from 'loops-tools';
const pageType = utils.getUrlParams('pageType');
// multiple
const { param1, param2 } = utils.getUrlParams('param1', param2);
pretty simple and all you need is focus on the page logic.
of course. if there are new APIs or features required. need to manually update the lib. but that also make this lib extensible and flexible.
Module structure:
utils, // include all utils. lke get url param and find, filter functions.
request, // method to request APIs. alias for utils.request. because frequently used
inapp, // in APP features. like DI, open APP page etc..
api, // APIS.
points, // di points
VERSION, // tools version. can see the release log to decide if this tools include requeired features.
Argument
paramName (array of string, string) : the param names
Returns
string or object
Example
const something = utils.getUrlParams('something');
const { param1, param2 } = utils.getUrlParams(['param1', 'param2']);
Argument
Returns
enum['Windows Phone', 'Android', 'iOS', 'unknown']
Example
Argument
Returns
number of chrome version
Example
include Lodash core (~4kb)
_.assignIn, _.before, _.bind, _.chain, _.clone, _.compact, _.concat, _.create, _.defaults, _.defer, _.delay, _.each, _.escape, _.every, _.filter, _.find, _.flatten, _.flattenDeep, _.forEach, _.has, _.head, _.identity, _.indexOf, _.isArguments, _.isArray, _.isBoolean, _.isDate, _.isEmpty, _.isEqual, _.isFinite, _.isFunction, _.isNaN, _.isNull, _.isNumber, _.isObject, _.isRegExp, _.isString, _.isUndefined, _.iteratee, _.keys, _.last, _.map, _.matches, _.max, _.min, _.mixin, _.negate, _.noConflict, _.noop, _.once, _.pick, _.reduce, _.result, _.size, _.slice, _.some, _.sortBy, _.tap, _.thru, _.toArray, _.uniqueId, _#value, & _.values
for more information: https://github.com/lodash/lodash/wiki/Build-Differences
https://mozat.com/confluence/pages/viewpage.action?title=Custom+URL&spaceKey=LC
Argument
dipoint: dipoint params: params.
Returns
Example
inapp.di(points(14012));
Argument
text: toast string.
Returns
Example
inapp.toast('toast test');
Argument
pageName: page name.
page name:
mydiamond,home,mylevel,leaderboard,mytitle,topup,myprofile
unlockType
(set only when pageName == "mytitle")
// -1: default
// 0: ‘all’
// 1: ‘broadcaster’
// 2: ‘looper ’
Returns
Example
inapp.openAppPage('mytitle');
Argument
sid: session id cid: channel id
Returns
Example
inapp.openVideo('v9495', '110012');
Argument
url: url title : title
Returns
Example
inapp.openURL('http://www.google.com', 'Google');
see code for more informations
see code for more informations
FAQs
loops api and all tools
The npm package loops-tools receives a total of 0 weekly downloads. As such, loops-tools popularity was classified as not popular.
We found that loops-tools demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
Security News
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
Security News
Research
A malicious npm package disguised as a WhatsApp client is exploiting authentication flows with a remote kill switch to exfiltrate data and destroy files.