hexo-codepen
A better version of hexo-tag-codepen with a valid HTML.
Install
Install using npm.
$ npm install hexo-codepen --save
or using yarn
$ yarn add hexo-codepen
Usage
Create Embedded Pen with following syntax:
{% codepen userId|anonymous|anon slugHash theme [defaultTab [height [width]]] %}
How to get arguments from CodePen embed
This is something generated by CodePen
:
See the Pen CSS sidebar toggle by Silvestar Bistrović (@CiTA) on CodePen.
You can extract required arguments:
Field | Value |
---|---|
userId | CiTA |
slugHash | bgjKKE |
theme | dark |
defaultTab | css,result |
height | 265 |
width | This value should be adjusted according to your blog theme, by default it is 100% |
License
MIT