I hereby claim:
- I am EmmaRamirez on github.
- I am emmaramirez (https://keybase.io/emmaramirez) on keybase.
- I have a public key whose fingerprint is DD43 6A6E F3DE 4D1D 1142 B6F8 369D FD8E 6C1C 5AC8
To claim this, I am signing this object:
window.addEventListener('DOMContentLoaded', () => { | |
const dialog = document.getElementById('dialog'); | |
console.log(dialog); | |
document.getElementById('open').addEventListener('click', () => { | |
dialog.show(); | |
}); | |
Array.from(document.querySelectorAll('.close')) | |
.forEach(f => { /* f is one button element */ | |
f.addEventListener('click', () => { | |
dialog.close(); |
<dialog id="dialog"> | |
<header> | |
<h1>Dialog Title</h1> | |
</header> | |
<p>Lorem ipsum dolor amet man bun irony letterpress ugh vexillologist. | |
Cronut synth craft beer, dreamcatcher organic adaptogen venmo activated | |
charcoal listicle trust fund food truck. Fixie pok pok skateboard franzen | |
food truck tattooed tousled raw denim shoreditch freegan adaptogen la croix | |
selfies prism. Pinterest actually meggings pickled, four dollar toast tilde | |
kinfolk art party iceland organic chicharrones tote bag 90's. Taiyaki vice |
I hereby claim:
To claim this, I am signing this object:
use serialize::json::Json; | |
use std::collections::TreeMap; | |
fn extract_string_map(json: Json) -> Result<TreeMap<String, String>, Json> { | |
let json = match json { | |
Json::Object(json) => json, | |
_ => return Err(json), | |
}; | |
if !json.iter().all(|(_k, v)| v.is_string()) { | |
return Err(Json::Object(json)); |