Skip to content

Commit cb11dcd

Browse files
committed
Use ESM
1 parent e9f6635 commit cb11dcd

File tree

8 files changed

+29
-25944
lines changed

8 files changed

+29
-25944
lines changed

.gitignore

-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
.DS_Store
22
*.log
3-
.nyc_output/
43
coverage/
54
node_modules/
6-
unist-util-source.js
7-
unist-util-source.min.js
85
yarn.lock

.npmc renamed to .npmrc

File renamed without changes.

.prettierignore

-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
coverage/
2-
unist-util-source.js
3-
unist-util-source.min.js
4-
*.json
52
*.md

index.js

+2-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,8 @@
1-
'use strict'
2-
3-
var location = require('vfile-location')
4-
5-
module.exports = source
1+
import location from 'vfile-location'
62

73
var search = /\r?\n|\r/g
84

9-
function source(value, file) {
5+
export function source(value, file) {
106
var doc = String(file)
117
var loc = location(file)
128
var position = (value && value.position) || value || {}

0 commit comments

Comments
 (0)