public function getAttributesFromFrontmatter($value)
    {
        $found = preg_match($this->pattern, $value, $matches);

        if (1 === $found) {
            return $this->getAttributesFromString($matches[1]);
        }

        return [];
    }
public function getAttributesFromFrontmatter($value)
    {
        $found = preg_match($this->pattern, $value, $matches);

        if (1 === $found) {
            return $this->getAttributesFromString($matches[1]);
        }

        return [];
    }
public function getAttributesFromFrontmatter ( $ value ) { $ found = preg_match ( $ this -> pattern , $ value , $ matches ) ; if ( 1 === $ found ) { return $ this -> getAttributesFromString ( $ matches [ 1 ] ) ; } return [ ] ; }
Get the attributes from the fronmatter of an item. Front-matter
block let you specify certain attributes of the page and define
new variables that will be available in the content.

e.g: (YAML syntax)
---
name: "Victor"
---

@param string $value Frontmatter

@return array Array with two elements: "attributes" and "content"
Get the attributes from the fronmatter of an item . Front - matter block let you specify certain attributes of the page and define new variables that will be available in the content .