The 10-second typing game
- Visit https://typerapp.now.sh/
- To start a game, type "start"
You now have 10 seconds to type out all the words displayed. For every word you type correctly, your score increases, and you also get 1 extra second. Can you beat my highscore of 16? (you probably can)
- 10 seconds to type
- Get an extra second for each word typed (small change of getting 2 seconds)
- Randomly get a password field to spice the game up (1/6 chance)
- Save your highscore locally
- Save your highscore in the leaderboards to compete with others
- leaderboards should reset every 2 weeks (not implemented yet)
Clone or fork the repository, then run the commands to start the development server:
npm i
npm run dev
To build the app, run
npm run build
First go to the Firebase console and create a new project. In src/scripts/
, add firebase.js
and paste the following:
import firebase from 'firebase/app';
const firebaseConfig = {
apiKey: '',
authDomain: '',
databaseURL: '',
projectId: '',
storageBucket: '',
messagingSenderId: '',
appId: '',
measurementId: ''
};
export const app = firebase.initializeApp(firebaseConfig);
firebase.auth().signInAnonymously().then(() => {
console.log('anonymous sign in successful');
}).catch((err) => {
console.log('error in sign in: ', err);
});
Fill up your details accordingly. Find these details on the Firebase console.
After this, go to the "Authentication" tab and enable anonymous sign in. Authentication is required to read and write the database.
The game is hosted with Vercel. To host a debug version of the app, run
now
To host the production version of the app, run
now --prod
If you liked this project, consider supporting by
MIT