Skip to content

v2.0.0

Compare
Choose a tag to compare
@github-actions github-actions released this 11 May 20:22
· 38 commits to main since this release

npm version

Documentation v2.0.0: https://raw.githack.com/kktjs/markdown-react-code-preview-loader/724b1f1/index.html
Comparing Changes: v1.3.0...v2.0.0

npm i markdown-react-code-preview-loader@2.0.0
import mdObj from 'markdown-react-code-preview-loader/README.md';

mdObj.source
mdObj.components
- mdObj.codeBlock
+ mdObj.data
{
-  codeBlock: {
-    17: 'import React from ...',
-    77: 'import React from ...',
-    demo12: 'import React from ...'
-  },
+  data: {
+    17: {
+      code: "\"use strict\";\n\nfunction ......"
+      language: "jsx"
+      name: 17,
+      value: "mport React from ..."
+    },
+    77: {
+      code: "\"use strict\";\n\nfunction ......"
+      language: "jsx"
+      name: 17,
+      value: "mport React from ..."
+    },
+    demo12: {
+      code: "\"use strict\";\n\nfunction ......"
+      language: "jsx"
+      name: 17,
+      value: "mport React from ..."
+    }
+  },
  components: { 17: ƒ, 77: ƒ, demo12: ƒ },
-  languages: { 17: 'jsx', 77: 'jsx', demo12: 'jsx'},
  source: "# Alert 确认对话框...."
}
- getCodeBlockString