Skip to content

Commit

Permalink
Renames default export to draft for better intellisense
Browse files Browse the repository at this point in the history
  • Loading branch information
webketje committed Dec 7, 2022
1 parent 0f3dc82 commit 4dd20fc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function isDraft(value, fallback) {
* metalsmith.use(drafts(true)) // same as { include: true }
* metalsmith.use(drafts({ default: false, include: false })) // same as default
*/
function configureDrafts(options = defaultOptions) {
function drafts(options = defaultOptions) {
if (typeof options === 'boolean') {
options = Object.assign({}, defaultOptions, { include: options })
} else {
Expand All @@ -51,4 +51,4 @@ function configureDrafts(options = defaultOptions) {
}
}

export default configureDrafts
export default drafts

0 comments on commit 4dd20fc

Please sign in to comment.