aboutsummaryrefslogtreecommitdiff
path: root/node_modules/markdown-it/lib/rules_core/block.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/markdown-it/lib/rules_core/block.js')
-rw-r--r--node_modules/markdown-it/lib/rules_core/block.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/node_modules/markdown-it/lib/rules_core/block.js b/node_modules/markdown-it/lib/rules_core/block.js
new file mode 100644
index 00000000..2a365fac
--- /dev/null
+++ b/node_modules/markdown-it/lib/rules_core/block.js
@@ -0,0 +1,16 @@
+'use strict';
+
+
+module.exports = function block(state) {
+ var token;
+
+ if (state.inlineMode) {
+ token = new state.Token('inline', '', 0);
+ token.content = state.src;
+ token.map = [ 0, 1 ];
+ token.children = [];
+ state.tokens.push(token);
+ } else {
+ state.md.block.parse(state.src, state.md, state.env, state.tokens);
+ }
+};