@ikilote/json2html
Advanced tools
Comparing version 0.3.0 to 0.4.0
# Changelog of json2html | ||
## V0.4.0 (2023-02-18) | ||
- add `Json2Js` to tranform json to js style | ||
## V0.3.0 (2023-02-17) | ||
@@ -4,0 +8,0 @@ |
{ | ||
"name": "@ikilote/json2html", | ||
"version": "0.3.0", | ||
"version": "0.4.0", | ||
"license": "MIT", | ||
@@ -26,3 +26,4 @@ "repository": { | ||
"xml", | ||
"json-to-html" | ||
"json-to-html", | ||
"json-to-js" | ||
], | ||
@@ -49,2 +50,2 @@ "module": "fesm2015/ikilote-json2html.mjs", | ||
"sideEffects": false | ||
} | ||
} |
export * from './lib/json2html'; | ||
export * from './lib/json2js'; |
@@ -13,2 +13,4 @@ # json2html | ||
Note for Angular: | ||
- 0.0.6 : for View Engine | ||
@@ -23,3 +25,3 @@ - 0.1.0+ : for Ivy | ||
### Examples | ||
### Example `Json2html` | ||
@@ -58,2 +60,37 @@ ```typescript | ||
### Example `Json2Js` | ||
```json | ||
{ | ||
"tag": "div", | ||
"attrs": { | ||
"id": "test", | ||
"class": "testclasse", | ||
"test": null, | ||
"data-test1": "`value1`", | ||
"data-test2": "'value2'", | ||
"data-test3": "\"value3\"" | ||
} | ||
} | ||
``` | ||
```typescript | ||
import { Json2html } from '@ikilote/json2html'; | ||
console.log(new Json2html(myJson, { tabSize: 2, tadAdded: 1 }).toString()); | ||
/* | ||
{ | ||
tag: 'div', | ||
attrs: { | ||
id: 'test', | ||
class: 'testclasse', | ||
test: null, | ||
'data-test1': '\`value1\`', | ||
'data-test2': `'value2'`, | ||
'data-test3': '"value3"' | ||
} | ||
} | ||
*/ | ||
``` | ||
## Publishing the library | ||
@@ -60,0 +97,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
134039
16
1152
109