Skip to content

Instantly share code, notes, and snippets.

@akoskm
Last active February 29, 2016 20:22
Show Gist options
  • Save akoskm/656faf037f083885fddd to your computer and use it in GitHub Desktop.
Save akoskm/656faf037f083885fddd to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<meta content="width=device-width,initial-scale=1" name="viewport">
<title>Work Description Generator</title>
<style>
body {
margin: 10px;
font-size: 16px;
}
input {
display: block;
height: 50px;
width: 250px;
margin-bottom: 5px;
}
.footer {
font-size: 14px;
}
</style>
</head>
<body>
<p>1. Click the button below</p>
<input type="button" onclick="work()" value="Generate Work Description"/>
<p>2. Copy the generated Work Description</p>
<input id="desc" onclick="this.select();" value/>
<p class="footer">This application was created for educational purposes.<br/>
<a href="https://gist.github.com/akoskm/656faf037f083885fddd">Fork it</a> to add your own words.</p>
</body>
<script>
var a = [
"integrate", "fix", "develop", "experiment with",
"work on", "investigate", "debug", "review", "refator",
"modularize", "implement", "improve", "test"
];
var b = [
"application", "user", "configuration", "issue",
"role", "account", "project"
];
var c = [
"workflow", "notifications", "resource"
];
var getRandomInt = function (min, max) {
return Math.floor(Math.random() * (max - min)) + min;
};
var work = function () {
var ai = getRandomInt(0, a.length);
var bi = getRandomInt(0, b.length);
var ci = getRandomInt(0, c.length);
var description = a[ai] + " " + b[bi] + " " + c[ci];
document.getElementById('desc').value = description;
};
</script>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment