-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Craig Freeman
committed
Aug 15, 2018
0 parents
commit 4c34f02
Showing
7 changed files
with
399 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
root = true; | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# See https://help.github.com/ignore-files/ for more about ignoring files. | ||
|
||
# dependencies | ||
/node_modules | ||
|
||
# misc | ||
.DS_Store | ||
|
||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"type": "node", | ||
"request": "launch", | ||
"name": "Launch Program", | ||
"program": "${workspaceFolder}/index.js" | ||
} | ||
] | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
[ | ||
"React", | ||
"Angular", | ||
"Vue", | ||
"Aurelia", | ||
"Polymer", | ||
"jQuery", | ||
"Vanilla JavaScript", | ||
"Backbone", | ||
"Preact", | ||
"Ext JS", | ||
"Elm", | ||
"cujoJS", | ||
"Dojo", | ||
"Meteor", | ||
"AngularJS", | ||
"Knockout", | ||
"CanJS", | ||
"Kendo UI", | ||
"Mithril", | ||
"Ember", | ||
"Marko", | ||
"Spine", | ||
"Matreshka.js", | ||
"Hyperapp", | ||
"Stencil" | ||
] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
const express = require('express'); | ||
const frameworks = require('./frameworks'); | ||
|
||
const app = express(); | ||
const port = process.env.PORT || 5001; | ||
|
||
app.get('/random', async (req, res) => { | ||
const randomFramework = Math.floor(Math.random() * Math.floor(frameworks.length)); | ||
|
||
res.json({ | ||
framework: frameworks[randomFramework] | ||
}); | ||
}); | ||
|
||
app.listen(port, err => { | ||
if (err) { console.log(err); } | ||
|
||
console.log(`API is now available at http://localhost:${port}`) | ||
}); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"name": "api", | ||
"version": "1.0.0", | ||
"main": "index.js", | ||
"license": "GPL 2", | ||
"private": true, | ||
"dependencies": { | ||
"express": "^4.16.3" | ||
} | ||
} |
Oops, something went wrong.