mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-10-12 14:01:58 +00:00
4.0.0-rc4.3
* Added: Settings Search * Added: Button to open the FFZ Control Center in a new window. * Added: Button to fade the FFZ Control Center.
This commit is contained in:
parent
a23bc74ae4
commit
0775cd1e77
23 changed files with 214 additions and 53 deletions
|
@ -146,6 +146,21 @@ export function filter_match(filter, target) {
|
|||
}
|
||||
|
||||
|
||||
export function substr_count(str, needle) {
|
||||
let i = 0, idx = 0;
|
||||
while( idx < str.length ) {
|
||||
const x = str.indexOf(needle, idx);
|
||||
if ( x === -1 )
|
||||
break;
|
||||
|
||||
i++;
|
||||
idx = x + 1;
|
||||
}
|
||||
|
||||
return i;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get a value from an object at a path.
|
||||
* @param {string|Array} path The path to follow, using periods to go down a level.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue