Skip to content

Instantly share code, notes, and snippets.

View allindeveloper's full-sized avatar
🏠
Working from home

Uchendu Precious allindeveloper

🏠
Working from home
View GitHub Profile
[
{
"code": "FC",
"name": "Abuja"
},
{
"code": "AB",
"name": "Abia"
},
{
@allindeveloper
allindeveloper / arrays101
Last active February 6, 2020 21:51
Array Assignment for VGG VIRTUAL INTERNSHIP
QUICK SIMPLE ASSIGNMENT
1.
We have the following arrays
color = ["Blue ", "Green", "Red", "Orange", "Violet", "Indigo", "Yellow "];
o = ["th","st","nd","rd"]
Write a JavaScript program to display the colors in the following way :
"1st choice is Blue."
"2nd choice is Green."
<!DOCTYPE html>
<html lang="en">
<body>
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<h4>Heading 4</h4>
<h5>Heading 5</h5>
<h6>Heading 6</h6>
<!DOCTYPE html>
<html lang="en">
<body>
<img src="flower.jpg" alt="Flowers in China">
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<body>
<section></section>
</body>
</html>
<a href="https://www.google.com/" title="Go to Google Home Page">Visit Google</a>
{
"employees": [
{
"id": 1,
"firstname": "Precious",
"lastname": "Uchendu",
"nationality": "Nigeria",
"gender":"Male",
"info":"Once Upon a time i could not code, now i can and i love it"
},
<html>
<head>
<title>JSON Server</title>
<link href="//netdna.bootstrapcdn.com/bootswatch/3.1.1/flatly/bootstrap.min.css" rel="stylesheet">
<link rel="stylesheet" href="stylesheets/style.css">
</head>
<body>
<div class="container">
<div class="jumbotron">
<h1>OPEN-JSON-API</h1>
var jsonServer = require('json-server');
var server = jsonServer.create();
var router = jsonServer.router('db.json');
var middlewares = jsonServer.defaults();
var port = Number(process.env.PORT || 3000);
server.use(middlewares);
server.use(router);
server.listen(port, function () {
console.log('JSON Server is running')
});
{
"employees": [
{
"id": 1,
"firstname": "Precious",
"lastname": "Uchendu",
"nationality": "Nigeria",
"gender":"Male",
"info":"Once Upon a time i could not code, now i can and i love it"
},