highmark-yapp 1.0.10 → 1.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +11 -6
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -73,23 +73,24 @@ renderYappStyles();
73
73
  ...
74
74
  ```
75
75
 
76
- Next, to create a node from some Markdown content, use the `nodeFromContent()` utility function:
76
+ Next, to create a node from some Markdown content, use the `tokensFromContent()` and `nodeFromTokens()` utility functions:
77
77
 
78
78
  ```
79
79
  import { markdownUtilities } from "highmark-yapp";
80
80
 
81
- const { nodeFromContent } = markdownUtilities;
81
+ const { tokensFromContent, nodeFromTokens } = markdownUtilities;
82
82
 
83
83
  const content = `
84
84
 
85
85
  ...
86
86
 
87
87
  `,
88
- node = nodeFromContent(node);
88
+ tokens = tokensFromContent(node),
89
+ node = nodeFromTokens(tokens);
89
90
 
90
91
  ```
91
92
 
92
- Then it is just a question of mounting the node within an [Easy](https://github.com/djalbat/easy) element:
93
+ Then it is just a question of mounting the node:
93
94
 
94
95
  ```
95
96
  import { Element } from "easy";
@@ -100,9 +101,13 @@ const { nodeFromContent } = markdownUtilities;
100
101
  class Article extends Element {
101
102
  didMount() {
102
103
  const { content } = this.constructor,
103
- node = nodeFromContent(content);
104
+ tokens = tokensFromContent(node),
105
+ node = nodeFromTokens(tokens);
106
+ domElement = this.getDOMElement(),
107
+ parentDOMElement = domElement, ///
108
+ siblingDOMElement = null;
104
109
 
105
- this.mount(node);
110
+ node.mount(parentDOMElement, siblingDOMElement, context);
106
111
  }
107
112
 
108
113
  willUnmount() {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "highmark-yapp",
3
3
  "author": "James Smith",
4
- "version": "1.0.10",
4
+ "version": "1.0.11",
5
5
  "license": "MIT, Anti-996",
6
6
  "homepage": "https://github.com/djalbat/highmark-uapp",
7
7
  "description": "Highmark with Yapp listings.",