Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
rastislavcore committed Apr 21, 2024
1 parent 5a35431 commit 7cb32ee
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 14 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ const makeReferenceLinkNode = (reference, text) => ({
],
});
const makeStrikethroughNode = (text) => ({
type: 'delete',
children: [{ type: 'text', value: text }],
type: 'text',
value: `~~${text}~~`,
});
const validateIcan = (address) => {
return Ican.isValid(address, true);
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "remark-corebc",
"version": "0.1.4",
"version": "0.1.5",
"description": "A Remark plugin to transform Core Blockchain notations into markdown links.",
"main": "dist/index.js",
"types": "types/index.d.ts",
Expand Down Expand Up @@ -43,13 +43,13 @@
"unist-util-visit": "^5.0.0"
},
"devDependencies": {
"@types/node": "^20.11.24",
"@types/node": "^20.12.7",
"esm": "^3.2.25",
"remark-parse": "^11.0.0",
"remark-stringify": "^11.0.0",
"ts-node": "^10.9.2",
"typescript": "^5.3.3",
"undici-types": "^6.6.2",
"typescript": "^5.4.5",
"undici-types": "^6.13.0",
"unified": "^11.0.4",
"uvu": "^0.5.6"
},
Expand All @@ -59,7 +59,7 @@
"exports": {
".": {
"import": "./dist/index.js",
"types": "./types/index.d.ts"
"types": "./dist/index.d.ts"
}
}
}
8 changes: 4 additions & 4 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ interface TextNode extends Node {
}

interface DelNode extends Node {
type: 'delete';
children: Array<TextNode>;
type: 'text';
value: string;
}

interface DefinitionNode extends Node {
Expand Down Expand Up @@ -126,8 +126,8 @@ const makeReferenceLinkNode = (reference: string, text: string): ReferenceLinkNo
});

const makeStrikethroughNode = (text: string): DelNode => ({
type: 'delete',
children: [{ type: 'text', value: text }],
type: 'text',
value: `~~${text}~~`,
});

const validateIcan = (address: string): boolean => {
Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"module": "Node16",
"outDir": "./dist",
"strict": true,
"forceConsistentCasingInFileNames": true,
"typeRoots": ["./node_modules/@types", "./types"],
"removeComments": true,
"declaration": true
Expand Down
4 changes: 1 addition & 3 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,5 @@ declare module 'remark-corebc' {
debug?: boolean;
}

function remarkCorebc(options?: CorebcOptions): (ast: Node) => void;

export default remarkCorebc;
export default function remarkCorebc(options?: CorebcOptions): (ast: Node) => void;
}

0 comments on commit 7cb32ee

Please sign in to comment.