Skip to content

Commit

Permalink
Remove duplicate docs and keep property matcher undocumented
Browse files Browse the repository at this point in the history
  • Loading branch information
youknowriad committed Nov 10, 2017
1 parent 456f054 commit 104a32a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 36 deletions.
3 changes: 1 addition & 2 deletions blocks/library/freeform/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ registerBlockType( 'core/freeform', {
attributes: {
content: {
type: 'string',
source: 'property',
property: 'innerHTML',
source: 'html',
},
},

Expand Down
34 changes: 0 additions & 34 deletions docs/attributes.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,40 +25,6 @@ _Example_: Extract the `src` attribute from an image found in the block's markup
// { "url": "https://lorempixel.com/1200/800/" }
```

### `attribute`

Use `attribute` to extract the value of an attribute from markup.

_Example_: Extract the `src` attribute from an image found in the block's markup.

```js
{
url: {
source: 'attribute',
selector: 'img',
attribute: 'src',
}
}
// { "url": "https://lorempixel.com/1200/800/" }
```

### `property`

Use `property` to extract the value of a property of a DOM Node from markup.

_Example_: Extract the `nodeName` property from a heading's node.

```js
{
tagName: {
source: 'property',
selector: 'h1,h2,h3,h4,h5,h6',
property: 'nodeName',
}
}
// { "tagName": "h2" }
```

### `text`

Use `text` to extract the inner text from markup.
Expand Down

0 comments on commit 104a32a

Please sign in to comment.