@soleil-se/app-util 1.0.3 → 1.0.5

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 +8 -0
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -16,6 +16,8 @@ Get HTML for rendering a Vue application.
16
16
  | name | `String` | | Name of the app, has to match the name of the Vue application. |
17
17
  | data | `Object` | | Data that will be available in `$options`. |
18
18
  | [noScript] | `String` | `''` | HTML that will be printed when JavaScript is not available. |
19
+
20
+ #### Example
19
21
  ```javascript
20
22
  router.get('/', (req, res) => {
21
23
  res.send(renderVue('AppName', data, noScript));
@@ -29,6 +31,8 @@ Get URI for a route.
29
31
  | Param | Type | Description |
30
32
  | --- | --- | --- |
31
33
  | route | `String` | A route. |
34
+
35
+ #### Example
32
36
  ```javascript
33
37
  const routeUri = getRouteUri('/my-route');
34
38
  ```
@@ -40,6 +44,8 @@ Get URI for a resource.
40
44
  | Param | Type | Description |
41
45
  | --- | --- | --- |
42
46
  | resource | `String` | A resource. |
47
+
48
+ #### Example
43
49
  ```javascript
44
50
  const resourceUri = getResourceUri('file/in/resource.png');
45
51
  ```
@@ -52,6 +58,8 @@ Renders a Underscore template and returns a string.
52
58
  | --- | --- | --- | --- |
53
59
  | template | `String` | | Underscore template. |
54
60
  | [values] | `Object` | `{}` | Values. |
61
+
62
+ #### Example
55
63
  ```javascript
56
64
  const string = renderTemplate('<div><%= foo %></div>', {
57
65
  foo: 'bar',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soleil-se/app-util",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "main": "./dist/index.js",
5
5
  "author": "Soleil AB",
6
6
  "license": "UNLICENSED",