UNPKG
@berun/runner-mdx-frontmatter
Version:
latest (7.3.6)
7.3.6
7.3.5
7.3.2
7.3.1
7.0.3
7.0.2
7.0.1
7.0.0
3.2.3
3.1.1
3.1.0
3.0.24
3.0.23
3.0.22
3.0.20
3.0.19
3.0.18
3.0.17
3.0.16
3.0.15
3.0.14
3.0.13
3.0.11
3.0.9
3.0.6
3.0.4
2.2.12
2.2.11
2.2.10
2.2.9
2.2.7
2.2.6
2.2.5
2.2.4
2.2.3
2.2.2
2.2.1
2.1.9
2.1.8
2.1.5
2.1.2
2.1.1
2.1.0
2.0.16
2.0.15
2.0.14
2.0.13
2.0.12
2.0.11
2.0.10
2.0.9
2.0.8
2.0.7
2.0.6
2.0.5
2.0.4
2.0.3
BeRun runner for using yaml frontmatter with MDX documentation applications
bestyled/berun
@berun/runner-mdx-frontmatter
/
src
/
loader
/
babel-fm-loader.ts
12 lines
(10 loc)
•
246 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
import
transform
from
'./transform'
export
default
async
function
(
this
: any, src
) {
const
callback =
this
.
async
()
try
{
const
result =
await
transform
(src)
return
callback
(
null
, result) }
catch
(ex) {
return
callback
(ex) } }