This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* I got tired of clicking through render arrays displayed in Kint looking for a | |
* specific string. So I wrote this function to find all instances of that string | |
* and give me back a copy-pasteable index for each location. | |
* | |
* @param $str The string you're searching for | |
* @param $arr A Drupal 8 Render array | |
* @return array Strings representing PHP array indices that contain your string within $arr | |
*/ |