A nice start to a collection of Magento 2 code snippets for Visual Studio Code!
Trigger: m2.log.objectmanager
Output:
\Magento\Framework\App\ObjectManager::getInstance()->get(\Psr\Log\LoggerInterface::class)->debug(__FILE__ .':' . __LINE__);
\Magento\Framework\App\ObjectManager::getInstance()->get(\Psr\Log\LoggerInterface::class)->debug(json_encode(context));
Trigger: m2.log.putcontent
Output:
file_put_contents('var/log/custom.log', __FILE__ .':' . __LINE__ . PHP_EOL, FILE_APPEND);
file_put_contents('var/log/custom.log', context . PHP_EOL, FILE_APPEND);
Trigger: m2.module.sequence
Output:
<sequence>
<module name="Vendor_Module" />
</sequence>