Skip to content

Commit

Permalink
v1.0.6
Browse files Browse the repository at this point in the history
  • Loading branch information
yoannchb-pro committed May 7, 2024
1 parent 5deff91 commit f8cdd70
Show file tree
Hide file tree
Showing 7 changed files with 280 additions and 107 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# CHANGELOG

## 1.0.6

- Fixed tokenizer
- WebPage

## 1.0.5

- Fixed github link
Expand Down
2 changes: 1 addition & 1 deletion dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

94 changes: 94 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>WTF JSON</title>
<script src="./dist/index.js"></script>
<style>
* {
padding: 0;
margin: 0;
box-sizing: border-box;
font-family: Arial, sans-serif;
}

body {
height: 100vh;
display: flex;
flex-direction: column;
background-color: #00dbde;
background-image: linear-gradient(90deg, #00dbde 0%, #fc00ff 100%);
}

a {
color: #fff;
font-weight: bold;
text-transform: uppercase;
text-align: center;
}

h1 {
font-size: 1.4rem;
}

header {
display: flex;
padding: 3rem;
align-items: center;
justify-content: center;
}

section {
display: flex;
flex-wrap: wrap;
height: 100%;
padding: 1rem;
gap: 1rem;
}

textarea {
border: none;
outline: none;
border-radius: 1rem;
resize: none;
overflow: auto;
flex: 1 1;
min-width: 20rem;
padding: 1rem;
background-color: rgba(255, 255, 255, 0.75);
}
</style>
</head>
<body>
<header>
<a href="https://github.com/yoannchb-pro/wtf-json" target="_blank"
><h1>wtfJson | A typescript librairie to parse any kind of JSON</h1></a
>
</header>
<section>
<textarea
id="input"
placeholder="Input (for example: [hello,, world])"
></textarea>
<textarea
id="output"
readonly
placeholder="Output (should give: ['hello', 'world'])"
></textarea>
</section>
</body>
<script>
const input = document.querySelector("#input");
const output = document.querySelector("#output");

const exec = () => {
const json = input.value;
const result = wtfJson(json);
if (json) output.value = JSON.stringify(result, undefined, 4);
else output.value = "";
};

input.addEventListener("input", exec);
</script>
</html>
20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@yoannchb/wtf-json",
"version": "1.0.5",
"version": "1.0.6",
"description": "Parse any kind of broken json for scrapping easily",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
Expand Down Expand Up @@ -36,14 +36,14 @@
},
"homepage": "https://github.com/yoannchb-pro/wtf-json#readme",
"devDependencies": {
"@rollup/plugin-terser": "^0.4.3",
"@types/jest": "^29.5.2",
"@types/node": "^20.3.3",
"jest": "^29.5.0",
"rollup": "^3.26.0",
"rollup-plugin-ts": "^3.2.0",
"ts-jest": "^29.1.1",
"ts-node": "^10.9.1",
"typescript": "^4.9.5"
"@rollup/plugin-terser": "^0.4.4",
"@types/jest": "^29.5.12",
"@types/node": "^20.12.10",
"jest": "^29.7.0",
"rollup": "^4.17.2",
"rollup-plugin-ts": "^3.4.5",
"ts-jest": "^29.1.2",
"ts-node": "^10.9.2",
"typescript": "^5.4.5"
}
}
Loading

0 comments on commit f8cdd70

Please sign in to comment.