Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

date: set up auto-generated API docs #14276

Merged
merged 3 commits into from
Mar 8, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use new script
  • Loading branch information
oandregal committed Mar 8, 2019
commit 6d8c994d09abe11d3c188b8f8d421cb71f67e350
2 changes: 1 addition & 1 deletion bin/update-readmes.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const packages = [
'blocks',
'compose',
//'data',
//'date',
'date',
'deprecated',
'dom',
'dom-ready',
Expand Down
14 changes: 7 additions & 7 deletions packages/date/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Formats a date (like `date()` in PHP), in the site's timezone.

**Returns**

`string` Formatted date.
`string`: Formatted date.

### dateI18n

Expand All @@ -45,7 +45,7 @@ Formats a date (like `dateI18n()` in PHP).

**Returns**

`string` Formatted date.
`string`: Formatted date.

### format

Expand All @@ -60,7 +60,7 @@ Formats a date. Does not alter the date's timezone.

**Returns**

`string` Formatted date.
`string`: Formatted date.

### getDate

Expand All @@ -74,7 +74,7 @@ Create and return a JavaScript Date Object from a date string in the WP timezone

**Returns**

`Date` Date
`Date`: Date

### gmdate

Expand All @@ -89,7 +89,7 @@ Formats a date (like `date()` in PHP), in the UTC timezone.

**Returns**

`string` Formatted date.
`string`: Formatted date.

### isInTheFuture

Expand All @@ -103,7 +103,7 @@ Check whether a date is considered in the future according to the WordPress sett

**Returns**

`boolean` Is in the future.
`boolean`: Is in the future.

### setSettings

Expand All @@ -123,7 +123,7 @@ Returns the currently defined date settings.

**Returns**

`Object` Settings, including locale data.
`Object`: Settings, including locale data.


<!-- END TOKEN(Autogenerated API docs) -->
Expand Down
6 changes: 0 additions & 6 deletions packages/date/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,7 @@
"moment": "^2.22.1",
"moment-timezone": "^0.5.16"
},
"devDependencies": {
"@wordpress/docgen": "file:../docgen"
},
"publishConfig": {
"access": "public"
},
"scripts": {
"docs:generate": "docgen ./src/index.js --output ./README.md --to-token"
}
}