Last active
April 8, 2019 05:47
-
-
Save katai5plate/525f91c893a985a0ca3674e1106ce4ea to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
0. Open RAW in this gist | |
1. Open DevTools | |
2. Open Console tab | |
3. Paste this: | |
document.body.innerHTML = document.body.innerText | |
4. Return to RUN | |
... | |
Example code: | |
document.body.innerText = [ | |
...document.querySelectorAll("tr") | |
] | |
.map(row => row | |
.innerText | |
.split("\t") | |
.map(text =>`"${text}"`) | |
) | |
.join("\n") | |
--> | |
<table> | |
<thead> | |
<tr> | |
<th><strong>店舗名</strong></th> | |
<th>メールアドレス</th> | |
<th>電話番号</th> | |
<th>FAX番号</th> | |
<th>所在地</th> | |
</tr> | |
</thead> | |
<tbody> | |
<tr> | |
<td>A店</td> | |
<td>a@example.com</td> | |
<td>01-1111-1111</td> | |
<td>01-1111-0000</td> | |
<td>東京都新宿区</td> | |
</tr> | |
<tr> | |
<td>"B"店</td> | |
<td>a@example.com</td> | |
<td>02-2222-2222,02-2222-2220(採用担当)</td> | |
<td>02-2222-0000</td> | |
<td>東京都中野区</td> | |
</tr> | |
</tbody> | |
</table> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment