Skip to content

Commit

Permalink
Set up auto-docs
Browse files Browse the repository at this point in the history
  • Loading branch information
oandregal committed Mar 6, 2019
1 parent 7d98658 commit 8cfa101
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bin/update-readmes.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const packages = [
//'autop',
//'blob',
//'block-editor',
//'block-library',
'block-library',
//'block-serialization-default-parser',
//'blocks',
//'compose',
Expand Down
15 changes: 14 additions & 1 deletion packages/block-library/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,25 @@ npm install @wordpress/block-library --save

_This package assumes that your code will run in an **ES2015+** environment. If you're using an environment that has limited or no support for ES2015+ such as lower versions of IE then using [core-js](https://github.com/zloirock/core-js) or [@babel/polyfill](https://babeljs.io/docs/en/next/babel-polyfill) will add support for these methods. Learn more about it in [Babel docs](https://babeljs.io/docs/en/next/caveats)._

## Usage
## API

<!-- START TOKEN(Autogenerated API docs) -->

### registerCoreBlocks

[src/index.js#L69-L130](src/index.js#L69-L130)

Function to register core blocks provided by the block editor.

**Usage**

```js
import { registerCoreBlocks } from '@wordpress/block-library';

registerCoreBlocks();
```


<!-- END TOKEN(Autogenerated API docs) -->

<br/><br/><p align="center"><img src="https://s.w.org/style/images/codeispoetry.png?1" alt="Code is Poetry." /></p>
10 changes: 10 additions & 0 deletions packages/block-library/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,16 @@ import * as tagCloud from './tag-cloud';

import * as classic from './classic';

/**
* Function to register core blocks provided by the block editor.
*
* @example
* ```js
* import { registerCoreBlocks } from '@wordpress/block-library';
*
* registerCoreBlocks();
* ```
*/
export const registerCoreBlocks = () => {
[
// Common blocks are grouped at the top to prioritize their display
Expand Down

0 comments on commit 8cfa101

Please sign in to comment.