🏃🚀 Checkpoint
./README.md:1954897/3016 ./server.js:1954897/5128 ./public/script.js:1954897/12752
This commit is contained in:
1 parent
6d92358f53
commit
1cde88a35f
2 files changed
+9
-27
No files matched your search
@@ -1,27 +1,7 @@
|
|||||||
Welcome to Glitch
|
# Tabú
|
||||||
=================
|
|
||||||
|
|
||||||
Click `Show` in the header to see your app live. Updates to your code will instantly deploy and update live.
|
Cada quien tendrá una palabra o frase en la frente. El objetivo es hacer que la digan.
|
||||||
|
|
||||||
**Glitch** is the friendly community where you'll build the app of your dreams. Glitch lets you instantly create, remix, edit, and host an app, bot or site, and you can invite collaborators or helpers to simultaneously edit code with you.
|
-----
|
||||||
|
|
||||||
Find out more [about Glitch](https://glitch.com/about).
|
Algunas imágenes proporcionadas por [unDraw](https://undraw.co/).
|
||||||
|
|
||||||
|
|
||||||
Your Project
|
|
||||||
------------
|
|
||||||
|
|
||||||
On the front-end,
|
|
||||||
- edit `public/client.js`, `public/style.css` and `views/index.html`
|
|
||||||
- drag in `assets`, like images or music, to add them to your project
|
|
||||||
|
|
||||||
On the back-end,
|
|
||||||
- your app starts at `server.js`
|
|
||||||
- add frameworks and packages in `package.json`
|
|
||||||
- safely store app secrets in `.env` (nobody can see this but you and people you invite)
|
|
||||||
|
|
||||||
|
|
||||||
Made by [Glitch](https://glitch.com/)
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
\ ゜o゜)ノ
|
|
||||||
+5
-3
@@ -3,6 +3,7 @@
|
|||||||
const wordBank = document.getElementById('wordBank')
|
const wordBank = document.getElementById('wordBank')
|
||||||
, input = document.getElementById('input')
|
, input = document.getElementById('input')
|
||||||
let prev = null
|
let prev = null
|
||||||
|
let palabras = fetch('palabras.json').then(x => x.json())
|
||||||
|
|
||||||
;[].forEach.call(
|
;[].forEach.call(
|
||||||
document.querySelectorAll('[data-open]'),
|
document.querySelectorAll('[data-open]'),
|
||||||
@@ -29,9 +30,10 @@
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
document.addEventListener('word', (e) => {
|
document.addEventListener('word', async function () {
|
||||||
// wordBank.innerHTML = ''
|
let words = (await palabras)
|
||||||
wordBank.innerHTML = Math.random()
|
console.log(words)
|
||||||
|
wordBank.innerHTML = words.words[~~(Math.random() * words.words.length)].p
|
||||||
})
|
})
|
||||||
|
|
||||||
document.addEventListener('fs', (e) => {
|
document.addEventListener('fs', (e) => {
|
||||||
|
|||||||
Reference in new issue
Block a user