File tree Expand file tree Collapse file tree 5 files changed +53
-1
lines changed
Expand file tree Collapse file tree 5 files changed +53
-1
lines changed Original file line number Diff line number Diff line change 3232 " Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)" ,
3333 " Anthony Maki <4cm4k1@gmail.com>"
3434 ],
35+ "types" : " types/index.d.ts" ,
3536 "files" : [
37+ " types/index.d.ts" ,
3638 " index.js"
3739 ],
3840 "dependencies" : {
4244 },
4345 "devDependencies" : {
4446 "browserify" : " ^17.0.0" ,
47+ "dtslint" : " ^3.0.0" ,
4548 "nyc" : " ^15.0.0" ,
4649 "prettier" : " ^2.0.0" ,
4750 "remark" : " ^13.0.0" ,
5053 "remark-preset-wooorm" : " ^8.0.0" ,
5154 "tape" : " ^5.0.0" ,
5255 "tinyify" : " ^3.0.0" ,
56+ "unified" : " ^9.0.0" ,
5357 "xo" : " ^0.37.0"
5458 },
5559 "scripts" : {
5963 "build" : " npm run build-bundle && npm run build-mangle" ,
6064 "test-api" : " node test" ,
6165 "test-coverage" : " nyc --reporter lcov tape test/index.js" ,
62- "test" : " npm run format && npm run build && npm run test-coverage"
66+ "test-types" : " dtslint types" ,
67+ "test" : " npm run format && npm run build && npm run test-coverage && npm run test-types"
6368 },
6469 "nyc" : {
6570 "check-coverage" : true ,
Original file line number Diff line number Diff line change 1+ // TypeScript Version: 3.4
2+
3+ import { Plugin } from 'unified'
4+
5+ declare namespace remarkGithub {
6+ type Github = Plugin < [ RemarkGithubOptions ?] >
7+
8+ interface RemarkGithubOptions {
9+ /**
10+ * Wrap mentions in `<strong>`, true by default.
11+ * @defaultValue true
12+ */
13+ mentionStrong ?: boolean
14+
15+ /**
16+ * Repository to link against.
17+ */
18+ repository ?: string
19+ }
20+ }
21+
22+ declare const remarkGithub : remarkGithub . Github
23+
24+ export = remarkGithub
Original file line number Diff line number Diff line change 1+ import unified = require( 'unified' )
2+ import github = require( 'remark-github' )
3+
4+ unified ( ) . use ( github )
5+ unified ( ) . use ( github , { } )
6+ unified ( ) . use ( github , { mentionStrong : false , repository : 'some/repo' } )
Original file line number Diff line number Diff line change 1+ {
2+ "compilerOptions" : {
3+ "lib" : [" es2015" ],
4+ "strict" : true ,
5+ "baseUrl" : " ." ,
6+ "paths" : {
7+ "remark-github" : [" index.d.ts" ]
8+ }
9+ }
10+ }
Original file line number Diff line number Diff line change 1+ {
2+ "extends" : " dtslint/dtslint.json" ,
3+ "rules" : {
4+ "semicolon" : false ,
5+ "whitespace" : false
6+ }
7+ }
You can’t perform that action at this time.
0 commit comments